Aan de slagGa gratis aan de slag

Adding columns

You finished the last set of exercises by creating an array called trunk_stump_diameters, which combined data from the trunk diameter and stump diameter columns into a 1D array. Now, you'll add that 1D array as a column to the tree_census array.

numpy is loaded as np, and both the tree_census and trunk_stump_diameters arrays are available.

Deze oefening maakt deel uit van de cursus

Introduction to NumPy

Cursus bekijken

Praktische interactieve oefening

Probeer deze oefening eens door deze voorbeeldcode in te vullen.

# Print the shapes of tree_census and trunk_stump_diameters
print(____)
Code bewerken en uitvoeren