You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* Try converting the column `plot_id` to floats using `surveys_df.plot_id.astype("float")`.
259
+
Then, try converting the contents of the `weight` column to an integer type.
260
+
What error messages does Pandas give you? What do these errors mean?
261
+
258
262
Pandas cannot convert types from float to int if the column contains NaN values.
259
263
260
264
### Challenge - Counting
265
+
266
+
* Count the number of missing values per column. Hint: The method `.count()` gives you the number of non-NA observations per column. Try looking to the `.isnull()` method.
267
+
268
+
~~~
261
269
surveys_df.isnull()
270
+
~~~
271
+
{: .language-python}
262
272
263
-
If the students have trouble generating the output, or anything happens with that, there is a file
264
-
called "sample output" that contains the data file they should generate.
273
+
If the students have trouble generating the output, or anything happens with that, the folder `sample_output` in this repository contains the file `surveys_complete.csv` with the data they should generate.
0 commit comments