Numpy And Pandas Flashcards
1
Q
What is a data frame and a series?
A
I’m pandas, a datagrams corresponds to column and rows (I.e. like a table or spreadsheet).
A series is a 1-d data frame - think of it like just a column (in pandas)
2
Q
What can a data frame be loaded from?
A
Sql, csv, excel file etc.
Or from a lost, dictionary or list of dictionaries
3
Q
Why is the setindex method important in pandas and what can happen if you don’t set an index?
A
the loc function does not work if you try to locate a piece of data without having first set (e.g. it’s column name) as an index
4
Q
which indices get used in what order in pandas? I.e. is it [row,column] or [column,row]?
A
[row,column]
5
Q
A