CHANGE COLUMN DTYPE | How to change the datatype of a column in Pandas (2020)

  Рет қаралды 23,268

Chart Explorers

Chart Explorers

Күн бұрын

Пікірлер: 33
@bryanparis7779
@bryanparis7779 2 жыл бұрын
The best video...i was searching in so many videos here and thanks to you I'm done:) MANY WISHESSSSS
@michaelmiachel1832
@michaelmiachel1832 2 жыл бұрын
Thank you! I've watched a lot of videos, but it was yours that helped me at a certain point👍
@amaanraza2704
@amaanraza2704 2 жыл бұрын
Explanation with rationale as to why we do it a certain way is exemplary
@7Dikano
@7Dikano 2 жыл бұрын
Hi, thank you! I have a problem while trying to convert 'missing' to int I have this error (IntCastingNaNError: Cannot convert non-finite values (NA or inf) to integer). Also my vs Code ipynb file won't recognise Int64: ..errors='coerce').astype(Int64)
@mahboobalam5689
@mahboobalam5689 2 жыл бұрын
It's a nicely explained tutorial. 👍
@darksider8207
@darksider8207 5 ай бұрын
can anyone explain at money col he replaces everything with empty string but i have loss which is indicated by - how can i keep the - sign for indicatiing loss and change its type to nu[meric ??
@experiencewithgeoffrey
@experiencewithgeoffrey 3 жыл бұрын
Thank you so much for this! :)
@ChartExplorers
@ChartExplorers 3 жыл бұрын
You're Welcome!
@arunimav6592
@arunimav6592 2 жыл бұрын
How to find out which of the columns are having a datatype object and convert them to string type ...i mean not specifically mentioning the column name..but by iterating and taking them automatically...PLS REPLY
@unknown7261
@unknown7261 2 жыл бұрын
Hello, I just want to ask what to do if a dataframe is displaying 1,500 even if the value on the excel is 1,500.00
@ChartExplorers
@ChartExplorers 2 жыл бұрын
When you read in the excel file you can specify the data type (dtype) of the column df = pd.read_excel('excel_file.xlsx', dtype={'col_a': float, 'col_d':float}) If your column of numbers has commas in (1,500.00) it you will have to read in the file, remove the commas and any other symbols and then convert to float. If you want two decimal places you can change it for the entire dataframe with the following pd.options.display.float_format = "{:,.2f}".format
@miketruong0808
@miketruong0808 3 жыл бұрын
Can you share the link to the video for converting column to datetime? It's not in your descriptions
@ChartExplorers
@ChartExplorers 3 жыл бұрын
Hi Mike, thanks for letting me know! I had forgotten to add the link kzbin.info/www/bejne/nGivgHeBfs-nl6M
@miketruong0808
@miketruong0808 3 жыл бұрын
@@ChartExplorers thank you. Your video was very helpful by the way
@ChartExplorers
@ChartExplorers 3 жыл бұрын
Thanks! I'm glad it helped (it makes it feel worth it when I know it actually helps out).
@mrmuranga
@mrmuranga 4 жыл бұрын
nice and short..thanks
@sergio_bandera
@sergio_bandera 2 жыл бұрын
Thank youuuuuuuuuuuuuuuuuuuu!!!!!!!!!!!!!!!!!!!!
@mr.sakshamjolly8972
@mr.sakshamjolly8972 2 жыл бұрын
really helpful bro... thanks for creating this video
@brandonjones5326
@brandonjones5326 3 жыл бұрын
Thanks for this!
@ChartExplorers
@ChartExplorers 3 жыл бұрын
You're welcome! :D
@honest_review2492
@honest_review2492 2 жыл бұрын
How to convert high and low in float
@honest_review2492
@honest_review2492 2 жыл бұрын
It is not working with any of your suggestions please help
@abdelrhmansayed340
@abdelrhmansayed340 Жыл бұрын
Thanks so much it is very informative.
@ridoychandraray2413
@ridoychandraray2413 2 жыл бұрын
Very helpful
@artibhardwaj5035
@artibhardwaj5035 3 жыл бұрын
Thanks alot u save my life
@ChartExplorers
@ChartExplorers 3 жыл бұрын
You're welcome, I'm glad it helped!
@shubhamjami5341
@shubhamjami5341 4 жыл бұрын
Thank you so much bro
@robiatuladawiyahal-qosh2916
@robiatuladawiyahal-qosh2916 2 жыл бұрын
Thank you!
@ameysonawane
@ameysonawane 3 жыл бұрын
thank you so much..!!
@ChartExplorers
@ChartExplorers 3 жыл бұрын
Did you figure out your error?
@ameysonawane
@ameysonawane 3 жыл бұрын
@@ChartExplorers yes.. thanks again.!
@QuietPenguinGaming
@QuietPenguinGaming 3 жыл бұрын
You completely skipped over the only column I cared about (missing) by saying "now we should be fully equipped to deal with this on our own". Abysmal tutorial and teacher.
@weronikajakubowska2976
@weronikajakubowska2976 Жыл бұрын
Thank you!
How to filter a pandas DataFrame | 6 HELPFUL METHODS
17:27
Chart Explorers
Рет қаралды 31 М.
25 Nooby Pandas Coding Mistakes You Should NEVER make.
11:30
Rob Mulla
Рет қаралды 278 М.
99.9% IMPOSSIBLE
00:24
STORROR
Рет қаралды 31 МЛН
Каха и дочка
00:28
К-Media
Рет қаралды 3,4 МЛН
1% vs 100% #beatbox #tiktok
01:10
BeatboxJCOP
Рет қаралды 67 МЛН
Clean Excel Data With Python Pandas - Removing Unwanted Characters
5:52
Derrick Sherrill
Рет қаралды 114 М.
How do I change the data type of a pandas Series?
7:29
Data School
Рет қаралды 134 М.
Loop / Iterate over pandas DataFrame (2020)
11:05
Chart Explorers
Рет қаралды 85 М.
How do I select multiple rows and columns from a pandas DataFrame?
21:47
How do I find and remove duplicate rows in pandas?
9:48
Data School
Рет қаралды 107 М.
When should I use a "groupby" in pandas?
8:25
Data School
Рет қаралды 246 М.