Python: import selected rows of dataframe. My data is in xlsx format -
hi beginner @ machine learning in python environment , want import first 30-40 rows of dataframe has 30.000 rows development.thank
you can use pandas.read_csv 'nrows' parameter, this:
pd.read_csv(myfilepath, nrows=30)
nrows : int, default none
number of rows of file read. useful reading pieces of large files
full documentation can found here
if want after read file:
dataframe.head(n=30)
Comments
Post a Comment