1. Learn
  2. /
  3. Courses
  4. /
  5. Introduction to Data Quality with Great Expectations

Connected

Exercise

Establish string Expectations

In this exercise, you'll practice establishing and validating some string-type Expectations, including parseability Expectations. As with the previous exercise, think critically about the Expectations you create in this exercise and whether or not you think they are befitting of the data.

A Batch connected to the Shein Footwear dataset has already been created and assigned to the variable batch. Great Expectations and pandas are available as gx and pd, respectively.

Instructions 1/4

undefined XP
  • 1
    • Print out the first few rows of the DataFrame to jog your memory about the data.
  • 2
    • Create an Expectation for the length of each of the "name" column values to be 100 characters.
    • Validate your Expectation.
  • 3
    • Create an Expectation that each value of the "name" column match the provided RegEx pattern.
    • Validate your Expectation.
  • 4
    • Create an Expectation that the values of the "name" column be parseable using dateutil.
    • Validate your Expectation.