Aan de slagGa gratis aan de slag

Transforming Data with an Expression

You have a client in the road safety sector who needs data on the acceleration of each electric vehicle. The acceleration data is given in the number of seconds taken to reach 100 km/h speed. The data is given to one decimal place, but this is more accuracy than you need.

Deze oefening maakt deel uit van de cursus

Introduction to Polars

Cursus bekijken

Oefeninstructies

  • Select the "brand","model" and "accel" columns where the acceleration is rounded to the nearest integer.

Praktische interactieve oefening

Probeer deze oefening eens door deze voorbeeldcode in te vullen.

# Select the brand, model and rounded accel columns
print(ev_df.select(____))
Code bewerken en uitvoeren