How to split huge .csv files to multiple .csv files based on size?
Afficher commentaires plus anciens
I am trying to split huge .csv files (11 GB) that has both combination of text and numbers into mutiple files based on size (0.5 GB each). I tried using some of the answers in the matlab community but no luck
I hope someone can help!
4 commentaires
dpb
le 21 Nov 2018
Shoulda' never created that large and unwieldy a text file to begin with... But you now know that, already... :)
Can you guesstimate how many lines are in the files at present? I'd probably just write a filter and copy N lines to a new file in a loop to determine that answer, then just put that in a nested loop until you run out of lines in the original. Lather, rinse, repeat...
Anjan
le 21 Nov 2018
Walter Roberson
le 21 Nov 2018
Modifié(e) : Walter Roberson
le 13 Fév 2021
Which OS? The easiest way to do this is with the unix split command , quite easy . For Windows I would look at https://www.gdgsoft.com/gsplit/
Anjan
le 25 Nov 2018
Réponse acceptée
Plus de réponses (0)
Catégories
En savoir plus sur Large Files and Big Data dans Centre d'aide et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!