Favorite Fruits: Statistics & Probability

Favorite Fruits: Statistics & Probability
Loading the math board and drawing, please wait…
2023-07-04 07:33
This example helps students understand data representation by having them create bar and pie charts of their favorite fruits. It uses GeoGebra commands such as Shuffle, Midpoint, Sequence, Point, If, Textfield, and Polygon. Suitable for 5-6th grade students to practice data statistics and chart creation.

GeoGebra Commands & Parameters

  1. Shuffle(Sequence[Random[1, 8], i, 1, 100]) → proz1, {3, 8, 1, 1, 3, 2, 3, 7, 3, 3, 8, 5, 4, 2, 4, 6, 8, 1, 5, 2, 2, 6, 3, 5, 3, 4, 7, 2, 2, 8, 3, 3, 1, 3, 3, 1, 8, 4, 6, 8, 7, 6, 8, 3, 5, 6, 7, 6, 4, 3, 3, 3, 8, 4, 5, 8, 7, 8, 6, 7, 1, 7, 1, 1, 6, 7, 2, 6, 6, 2, 1, 3, 5, 2, 3, 8, 4, 7, 2, 4, 1, 7, 4, 2, 7, 4, 1, 8, 1, 3, 2, 3, 8, 7, 1, 2, 4, 7, 4, 8}
  2. Shuffle(Sequence[Random[1, 9 - selectedProz1 / 10], i, 1, 100]) → proz2, {1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1}
  3. Shuffle({50, 100, 120}) → prozentstreifen, {50, 120, 100}
  4. Midpoint(PosTopRight, PosBottomRight) → midPointEnd
  5. Midpoint(PosTopLeft, PosBottomLeft) → midPointStart
  6. Sequence(midPointStart + (i * (prozentMillimeter, 0)), i, 0, endPointObst1) → allowedPosObst1
  7. Point(allowedPosObst1) → PObst1
  8. If(x(PObst1) < 0, (abs(x(PObst1)) + x(midPointEnd)) / (prozentMillimeter), (x(midPointEnd) - x(PObst1)) / (prozentMillimeter)) → endPointObst2
  9. Sequence(PObst1 + (i * (prozentMillimeter, 0)), i, 0, endPointObst2) → allowedPosObst2
  10. Point(allowedPosObst2) → PObst2
  11. If(x(PObst2) < 0, (abs(x(PObst2)) + x(midPointEnd)) / (prozentMillimeter), (x(midPointEnd) - x(PObst2)) / (prozentMillimeter)) → endPointObst3
  12. Sequence(PObst2 + (i * (prozentMillimeter, 0)), i, 0, endPointObst3) → allowedPosObst3
  13. Point(allowedPosObst3) → PObst3
  14. Textfield(input1) → InputBox1
  15. Textfield(input2) → InputBox2
  16. Shuffle({"Apfel", "Birne", "Banane", "Mango", "Kirsche", "Tomate", "Pfirsich", "Marille"}) → Obst, {"Banane", "Apfel", "Kirsche", "Pfirsich", "Birne", "Marille", "Tomate", "Mango"}
  17. Polygon(PosTopLeft, PosTopRight, PosBottomRight, PosBottomLeft) → box, postopleft, postopright, posbottomright, posbottomleft
  18. Polygon(PosTopLeft, (x(PObst1), y(PosTopLeft)), (x(PObst1), y(PosBottomLeft)), PosBottomLeft) → boxObst1, f, g, h, i
  19. Polygon((x(PObst1), y(PosTopLeft)), (x(PObst1), y(PosBottomLeft)), (x(PObst2), y(PosBottomLeft)), (x(PObst2), y(PosTopLeft))) → boxObst2, j, k, l, m
  20. Polygon((x(PObst2), y(PosTopLeft)), (x(PObst2), y(PosBottomLeft)), (x(PObst3), y(PosBottomLeft)), (x(PObst3), y(PosTopLeft))) → boxObst3, n, p, q, r
  21. Midpoint(PosTopLeft_{1}, PosBottomLeft_{1}) → midPointStart_{1}
  22. Midpoint(PosTopRight_{1}, PosBottomRight_{1}) → midPointEnd_{1}
  23. Polygon(PosTopLeft_{1}, PosTopRight_{1}, PosBottomRight_{1}, PosBottomLeft_{1}) → boxLoesung, postopleft_{1}, postopright_{1}, posbottomright_{1}, posbottomleft_{1}
  24. Polygon(PosTopLeft_{1}, PosBottomLeft_{1}, (x(PSol1), y(PosBottomLeft_{1})), (x(PSol1), y(PosTopLeft_{1}))) → boxObst1Sol, c, d, e, f_1
  25. Polygon((x(PSol1), y(PosBottomLeft_{1})), (x(PSol1), y(PosTopLeft_{1})), (x(PSol2), y(PosTopLeft_{1})), (x(PSol2), y(PosBottomLeft_{1}))) → boxObst2Sol, s, t, a, b
  26. Polygon((x(PSol3), y(PosBottomLeft_{1})), (x(PSol3), y(PosTopLeft_{1})), (x(PSol2), y(PosTopLeft_{1})), (x(PSol2), y(PosBottomLeft_{1}))) → boxObst3Sol, g_1, h_1, i_1, j_1

AI Drawing Prompt Reference

Create an interactive chart for favorite fruit statistics showing a main rectangle divided into three adjustable vertical bars representing three randomly ordered fruit names; include two text input boxes for students to enter percentages; add a solution rectangle beside or below displaying the correct bar widths; all bars are drawn as rectangular polygons whose edges are controlled by draggable points, arranged neatly for elementary students to practice data representation and chart making.
The prompt above was compiled from the original drawing commands and is for reference only.