Data I/O and Preprocessing with Python and SQL — Module 2 grader mismatch (Exercises 3, 5, 6, 8) despite correct output

I’ve executed all the steps 1-4, but the error is still with me:

I’m unable to pass the grader for Module 2’s graded lab, despite extensive manual verification that my code and output are correct. Details below:

Exercise 3 (convert columns to numeric):

  • Error: “The following columns in census_df_clean do not have the correct type”
  • I verified: all listed columns show as int64 (also tried float64) via .dtypes, with no NaN or inf values.
  • Tried: pd.to_numeric(), explicit .astype(float), full kernel restart + run all + save before each grading attempt.

Exercise 5 (poverty rate calculations):

  • Error: “The values in the column ‘total_poverty_rate’/‘under_5_poverty_rate’/‘over_75_poverty_rate’ do not match the expected values”
  • I verified: the first 5 rows of my output match the expected output screenshot in the assignment exactly (e.g., 0.096262, 0.175305, 0.043644 for row 0).
  • Full dataset checked: no NaN, no inf, 826 rows, clean monotonic index starting at 0.

Exercise 6 (vulnerability score):

  • After fixing a naming confusion (used under_5_poverty_rate instead of the correct under_5_poverty_proportion per the formula in the directions), the histogram now visually matches the expected output shape.

Exercise 8 (z-score outliers):

  • Error: “The values in the column ‘z_score’ do not match the expected values”
  • I compared standard ddof=1 (.std()) vs ddof=0 (scipy.stats.zscore) against a provided expected-output screenshot — ddof=1 (Pandas default .std()) gives near-exact matches (differences ~0.0006%), but the grader still fails.

Troubleshooting already performed (multiple times, per support’s suggestion):

  • Kernel → Restart & Run All, in order, from the first cell.
  • Saved the notebook (Ctrl+S) both before and after running all cells, and again before each grading attempt.
  • Confirmed no provided/locked helper-code cells were modified.
  • Checked for duplicate # GRADED CELL markers — none found.

Given that the computed values visually and numerically match the expected outputs shown in the assignment instructions, I suspect this may be a grader-side issue (e.g., stale reference data, or a mismatch in the grader’s expected dtype) rather than an error in my code. Screenshots of the grader feedback and expected outputs are attached.

Could someone review the grading script for these specific exercises, or confirm the exact expected dtype/computation method?

Thank you,
Grigori Azaryants

Thank you. We got your notebook via direct message. Will try to resolve it by Monday, if not sooner. You can move on to the next part of the course in the meantime. Hope that’s okay.

Thank you too. That’s definitely OK.