Python Forum
How can I add certain elements in this 2d data structure and calculate a mean
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
How can I add certain elements in this 2d data structure and calculate a mean
#2
myClass is a list of students, so your loop could look like
for myStudent in myClass:
    # do something with myStudent
Each student's data is a 1D data structure (a Python list here).
TheOddCircle likes this post
Reply


Messages In This Thread
RE: How can I add certain elements in this 2d data structure and calculate a mean - by Gribouillis - May-26-2022, 08:19 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  script to calculate data in csv-files ledgreve 0 1,134 May-19-2023, 07:24 AM
Last Post: ledgreve
  ValueError: Length mismatch: Expected axis has 8 elements, new values have 1 elements ilknurg 1 5,227 May-17-2022, 11:38 AM
Last Post: Larz60+
Question Change elements of array based on position of input data Cola_Reb 6 2,185 May-13-2022, 12:57 PM
Last Post: Cola_Reb
  calculate data using 1 byte checksum korenron 2 3,001 Nov-23-2021, 07:17 AM
Last Post: korenron
  Appropriate data-structure / design for business-day relations (week/month-wise) sx999 2 2,829 Apr-23-2021, 08:09 AM
Last Post: sx999
  what data structure to use? Winfried 4 2,864 Mar-16-2021, 12:11 PM
Last Post: buran
  Yahoo_fin, Pandas: how to convert data table structure in csv file detlefschmitt 14 7,874 Feb-15-2021, 12:58 PM
Last Post: detlefschmitt
  Sorting Elements via parameters pointing to those elements. rpalmer 3 2,646 Feb-10-2021, 04:53 PM
Last Post: rpalmer
  How to use Bunch data structure moish 2 2,949 Dec-24-2020, 06:25 PM
Last Post: deanhystad
  Correct data structure for this problem Wigi 13 4,711 Oct-09-2020, 11:09 AM
Last Post: buran

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020