Which of the following objects are raw data? (As opposed to processed data.)
Answers:
A Web page downloaded using urllib.request.urlopen() or saved from a Web browser.
A table that contains the frequencies of each unique word in Moby Dick.
A TIFF image file obtained by scanning a book page.
The text of Moby Dick extracted from a scanned image using optical character recognition
(OCR). correct answers A Web page downloaded using urllib.request.urlopen() or saved from a
Web browser.
A TIFF image file obtained by scanning a book page.
Which data analysis technique is a machine learning technique?
Answers:
Information retrieval.
Linear regressions.
Decision trees.
Signal processing. correct answers Decision trees.
,Is it a good idea to use interactive GUI tools for reproducible data analysis (as opposed to
command-line programmed tools), and why?
Answers:
No, it is not. Interactive GUI tools do not record the history of operations, which makes the
analysis not reproducible.
No, it is not. Interactive GUI tools are usually oversimplified, stripped down versions of
powerful programmable data processing environments.
Yes, it is. Interactive GUI tools simplify data analysis and make it more accessible.
Yes, it is. Interactive GUI tools, as a rule, provide more powerful data analysis techniques.
correct answers No, it is not. Interactive GUI tools do not record the history of operations, which
makes the analysis not reproducible.
Alice noticed that the scatter plot of variable Y vs variable X that she plotted as a part of the
exploratory data analysis, looks almost like a straight diagonal line. What statement is Alice
entitled to make, based on this observation?
Answers:
A change in X causes a change in Y.
X and Y are correlated.
A change in Y causes a change in X.
A change in X causes a change in Y and a change in Y causes a change in X. correct answers X
and Y are correlated.
,s is a Python string. What does the function s.upper() return?
Answers:
A copy of s with each alphabetic character converted to the upper case.
A reference to s where each alphabetic character has been converted to the upper case and all
other characters removed.
A copy of s with each alphabetic character converted to the upper case and all other characters
removed.
A reference to s where each alphabetic character has been converted to the upper case. correct
answers A copy of s with each alphabetic character converted to the upper case.
Which statement converts a string s into a list of unique vowels?
Answer:
list(set(c for c in s if c in "aouieAOUIE"))
[c for c in s if c in "aouieAOUIE"]
set(c for c in s if c.isvowel())
list([c for c in s if c in "aouieAOUIE"]) correct answers list(set(c for c in s if c in
"aouieAOUIE"))
infile is an open file of an unknown size. Which functions can be safely used to read from this
file? (Check all that apply.)
, Answers:
infile.read(100)
infile.readline()
infile.readlines()
infile.read() correct answers infile.read(100)
infile.readline()
Bob attempts to download a data file using the follolwing statement:
data = urllib.request.urlopen ("http://foo.bar/foobar.tgz")
However, the URL http://foo.bar/foobar.tgz is no longer valid. What will be the value of the
variable data after the execution of the statement?
Answers:
The statement raises an exception. The variable data does not exist.
The value of data is None.
The value of data is unknown.
The value of data is an empty string. correct answers The statement raises an exception. The
variable data does not exist.