Professional Documents
Culture Documents
Activiy 2. Hands and Fingers
Activiy 2. Hands and Fingers
● https://accounts.google.com/ServiceLogin
1
Use a ruler to measure the length of fingers on your left hand.
finger length in cm
1
2
3
4
5
2
Click on this link to open a notebook:
● https://tinyurl.com/y4yuhvr3
3
We need our own copy of the notebook.
4
We’re going to be using a coding language called python.
Run the code that imports pandas by clicking the play button:
5
In the code you can see a list of finger lengths.
6
We now need to turn that list into a dataframe.
A dataframe can have lots of rows and columns. A dataframe can also
have names for each column or row.
Run the next cell which turns our list left_fingers into a dataframe
called left_hand_df.
Printing the dataframe looks nicer than printing the list we saw earlier.
7
Let’s draw a picture showing the lengths of our fingers.
Your chart will look different because your hand is different to mine!
8
Let’s now try our right hand.
Use a ruler to measure the length of fingers on your left hand. Make sure
you start with your thumb first.
finger length in cm
1
2
3
4
5
9
Further down the notebook is a cell where you can put your right hand
finger lengths into a list called right_fingers.
Just like before, turn the list into a dataframe called right_hand_df.
10
Draw a bar chart for your right hand.
Do the charts for your left and right hands look different?
11
Let’s compare our left and right hands.
The next few notebook cells show how you can find out the longest and
shortest finger lengths for each hand.
You can also see how to find out the mean average finger length too.
You’ll need to change the code in the notebook to complete the table.
Using the numbers in the table, can you decide which hand is bigger?
12
It would be easier to see information about both hands together.
You can see that we’ve changed the column names to be ‘left’ and
‘right’.
13
Let’s draw a chart showing both hands.
This is easy because the new dataframe has data about both hands.
Change the code so your chart has your name in the title.
14