89.9k views
5 votes
Write a program to load a given dataset called Student_Grades.csv into a NumPy array. Then determine the following items:

Display all data on screen.

1 Answer

2 votes

Final answer:

To load the Student_Grades.csv dataset into a NumPy array, use the genfromtxt function. Print the data array to display all the data on the screen.

Step-by-step explanation:

To load the given dataset called Student_Grades.csv into a NumPy array, you can use the `genfromtxt` function from the NumPy library. Here is an example code:

import numpy as np
# Load the dataset
data = np.genfromtxt('Student_Grades.csv', delimiter=',')

This code imports the NumPy library and then uses the `genfromtxt` function to load the dataset into the `data` variable. The delimiter parameter specifies the character used to separate the values in the CSV file.

To display all the data on the screen, you can simply print the `data` array using:

print(data)

User RonanC
by
8.7k points