Complete the code to run data validation using Great Expectations in the CI pipeline.
import great_expectations as ge import pandas as pd data = ge.dataset.PandasDataset(pd.read_csv('data.csv')) results = data.[1]()
The validate() method runs the data validation checks defined in Great Expectations.
Complete the code to load the Great Expectations suite named 'my_suite' for validation.
from great_expectations.data_context import DataContext context = DataContext() suite = context.get_expectation_suite('[1]')
The suite name 'my_suite' is used to load the specific expectation suite for validation.
Fix the error in the command to run data validation in the CI pipeline using Great Expectations CLI.
great_expectations [1] --suite my_suite --data-dir ./dataThe correct CLI command to run validation is great_expectations validate.
Fill both blanks to create a Python dictionary comprehension that filters data rows where 'age' is greater than 18.
filtered_data = {row['id']: row for row in data if row['[1]'] [2] 18}The key 'age' is checked to be greater than 18 using the '>' operator.
Fill all three blanks to create a dictionary comprehension that maps uppercase 'name' to 'score' for scores above 50.
result = [1]: [2] for item in data if item['score'] [3] 50
The comprehension maps uppercase names to scores where score is greater than 50.