Skip to content
C

Problem 1: Apply Standardization to a Dataset

Easypython

Problem Description

Write a Python program that applies StandardScaler to a DataFrame with two numeric columns, and prints the scaled result.

Input

A DataFrame with two numeric columns.

Output

The standardized DataFrame (mean 0, std 1 for each column).

Constraints

  • Columns will contain at least 3 numeric values each.

Example Input

text
{"age": [20, 30, 40], "salary": [30000, 50000, 70000]}

Example Output

text
(Standardized values with mean approximately 0 and std approximately 1 for each column)

Concepts Covered

StandardScaler, fit_transform().

Input (stdin)

Output

Run your code to see output here...