-
Notifications
You must be signed in to change notification settings - Fork 5
Conversation
" :param by: \"all\", \"domain\" or \"year\" the output to return\n", | ||
" :param minline: the minimum size of a line to be included in the output\n", | ||
" :param by: \"all\", \"domain\" or \"year\" the output to return.\n", | ||
" :param minline: the minimum size of a line to be included in the output.\n", | ||
" :return: [(year/domain, text)] or [text] depending on by\n", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@greebie the return comment here seems to be missing something. What should it read?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe :return: [({year or domain}, textString)] if
by is 'domain' or 'year', otherwise [textString]\n
is more clear - it is also possible to include the type using :rtype: but I don't think that is too necessary.
"# characters to show per text file in output. Larger numbers will results in more\n", | ||
"# text showing in output\n", | ||
"# Characters to show per text file in output.\n", | ||
"# Larger numbers will results in more text showing in output.\n", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
"will results" -> "will result"
"# If you have a large file but want to sample the file more broadly, you\n", | ||
"# can increase this value skip to every Nth line.\n", | ||
"# If you have a large file but want to sample the file more broadly.\n", | ||
"# You can increase this value skip to every Nth line.\n", | ||
"RESULTS_STEP = 5\n", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I wonder if RESULTS_STEP should be changed to 1
for the default example? This var (plus RESULTS_START & RESULTS_LIMIT) is used basically so that we do not potato browsers. Right now, the analysis takes every 5th line starting from 0 and going to 2500, for a total of 500 lines. Alternately, we could keep RESULTS_STEP the same, and increase RESULTS_LIMIT to get more results.
"def write_output (stdout, results):\n", | ||
" \"\"\" Writes results to file.\n", | ||
" \n", | ||
" :param stdout: Filepath for file\n", | ||
" :param results: A list of results.\n", | ||
" :return: Nothing\"\"\"\n", | ||
" :return: Nothing\n", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
:return: None\n
is the correct pydoc response here.
"mapping = {x[0]: x[1] for x in graph.nodes('label')}\n", | ||
"\n", | ||
"# Use Archive Unleashed Clouds Positions (saves on load time)\n", | ||
"# Use Archive Unleashed Clouds Positions (saves on load time).\n", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Positions == positions.
"mapping = {x[0]: x[1] for x in neigh.nodes('label')}\n", | ||
"\n", | ||
"# Use Archive Unleashed Clouds Positions (saves on load time)\n", | ||
"# Use Archive Unleashed Clouds Positions (saves on load time).\n", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Positions == positions
If we're good with the review commit, I'll move on to the other notebook. Then get the other dataset in other PR. |
changes lgtm. |
Both notebooks are added now. Let me know if there are any issues. If there are none, commit message should just be: Title: |
Close read of text and comments. I'll start with the example notebook, and move on to the other.