I am teaching about frequency tables and reading probabilities off of them. In the first two screens, students answer questions and the data is collected and shows up in the next set of screens. In those following screens, students are asked to find specific probabilities based on the information in the collected data. However, I cannot seem to get those to work. Can anyone help?

I found two errors which may correct it.

On screen 3, I changed the CL to:

```
table = class2
#you needed to increase the second numbers by 1 because of title column in the other table
a1 = table.cellNumericValue(1,2)
b1 = table.cellNumericValue(1,3)
c1 = table.cellNumericValue(1,4)
a2 = table.cellNumericValue(2,2)
b2 = table.cellNumericValue(2,3)
c2 = table.cellNumericValue(2,4)
a3 = table.cellNumericValue(3,2)
b3 = table.cellNumericValue(3,3)
c3 = table.cellNumericValue(3,4)
#for division, you need to use this \frac{}{} notation
cellContent(1,3): when numericValue("\frac{${a3}}{${c3}}")= class3.cellNumericValue(1,2) "✅" otherwise "❌"
cellContent(2,3): when numericValue("\frac{${b3}}{${c3}}")= class3.cellNumericValue(2,2) "✅" otherwise "❌"
cellContent(3,3): when numericValue("\frac{${c1}}{${c3}}")= class3.cellNumericValue(3,2) "✅" otherwise "❌"
cellContent(4,3): when numericValue("\frac{${c2}}{${c3}}")= class3.cellNumericValue(4,2) "✅" otherwise "❌"
correct:
class3.cellContent(1,3)="✅" and class3.cellContent(2,3)="✅" and class3.cellContent(3,3)="✅" and class3.cellContent(4,3)="✅"```
```

1 Like