Questions tagged [csv-format]

Questions about the Text based file format CSV (Comma Seperated Values). Questions include, but are not restricted to, importing from and exporting to this file format.

Filter by
Sorted by
Tagged with
0 votes
0 answers
46 views

ListLinePlot: Options expected (instead of ImportCSVToDataset

I have the following code ...
user avatar
2 votes
1 answer
66 views

How to import CSV file with mixed data, including string Mathematica expressions and numbers

I am importing a CSV file that looks like this (Extract of data as viewed in Notepad): ...
user avatar
  • 21
0 votes
1 answer
59 views

It's about manipulating .csv file

Actually I load .csv file about movies to Mathematica and store it in "dt", and there is one column records the production countries which is the first column df[[All,{1}]]. And the format ...
user avatar
3 votes
3 answers
121 views

Exporting CSVs of UTM coordinates. How to stop northing exporting in scientific notation?

I need to batch convert a folder of CSVs containing UTM coordinates from GDA94 to GDA2020. Sample data below: Copyable form: ...
user avatar
  • 31
0 votes
1 answer
45 views

How can I save the eigenvalues of a 1000x1000 COE matrix and 500x500 COE matrix in the same file?

I have generated eigenvalues of '1' 1000x1000 matrix of CircularOrthogonalEnsemble and saved it in a csv file using Export. Now ...
user avatar
0 votes
1 answer
111 views

Converting JSON to CSV but the formatting is not correct

I have a folder of about a million JSON files and I wrote this to convert them quickly to CSV, but the formatting is not correct for the software I'm feeding them into. Here's the code I'm using: <...
user avatar
  • 4,370
2 votes
2 answers
86 views

Exporting a Large List to a CSV File Kills Kernel in 12.3?

I noticed that Mathematica 12.3 (also 12.1) kills the kernel when I try to Export a large list to a CSV file. No error messages, no warning, just a hard stop. Here is the code I wrote to replicate the ...
user avatar
  • 81
0 votes
2 answers
48 views

Data wrangling to create a matrix from lists

I have a super simple data wrangling question that I can't seem to figure out (I am new to Mathematica). Basically I'm not sure what function to use. I have two parameters, ...
user avatar
  • 1
0 votes
1 answer
71 views

Exporting complex exponential float arrays to Python

A question related to a previous question. The answer in the previous question works well for simple complex arrays but not when considering arrays with exponential float coefficients as in the ...
user avatar
  • 271
22 votes
2 answers
1k views

How to make Mathematica read in CSV as fast as Python's Pandas

I have many big CSV files for processing in Mathematica. And each time loading them into Mathematica takes a long time. Meanwhile, it takes much less time using Pandas under Python. For example, ...
user avatar
  • 4,157
1 vote
1 answer
133 views

Editing complex arrays for export to Python

Quick question, can anyone advise on an efficient way to convert complex arrays with complex part denoted '${I}$' in Mathematica to '$j$' (as used in Python) and curly brackets '{}' replaced with '[]' ...
user avatar
  • 271
1 vote
2 answers
70 views

Import all elements in a specific column from a CSV file given the name of the column

I have a large CSV file with many columns (300 MB). I know their names. I don't know the column numbers. How can I efficiently import a column for inspection by name? Here is a tiny example file: <...
user avatar
0 votes
2 answers
149 views

Import from CSV formatting issue

I have two lists of data here: dm and dmHalo (see attached image). Theses are the same lists, the only difference is that dm was exported to a csv file and then reimported, while dmHalo was generated ...
user avatar
  • 11
4 votes
2 answers
156 views

Organising and examining a complicated CSV file

I am being sent data in CSV files. The sender is providing helpful comments and lots of headings so that it is fine to look at in a spreadsheet environment. However, when I import it into Mathematica ...
user avatar
  • 14.7k
1 vote
1 answer
50 views

Import of csv-data don't read columns

I couldn't catch the point: when I try to read an easy csv-dataset with ";" as delimiter, I get only "strings" instead of a set of columns. Here are two lines of the csv-File: k_id;...
user avatar
  • 13
3 votes
1 answer
467 views

Formatting Imported Complex Arrays from Python (csv. files)

Just a short question, I am trying to import a complex array (matrix) from Python to Mathematica by first writing to a csv. file. When I Import the csv. array to Mathematica it is in a form (matrix ...
user avatar
  • 271
2 votes
2 answers
116 views

Plot the complete dataset as listplots

I have imported as a csv file and converted to a Dataset. The data is in the following csv format ...
user avatar
2 votes
2 answers
182 views

How to Listplot data from huge DataSet?

I have this data set in .csv and I imported them to mathematica to analyze them using Import function. Now here I have only shown a part of the dataset just to give an example of how it looks in Excel....
user avatar
1 vote
1 answer
58 views

Incomplete data transfer: large CSV data Import, computation outputs exported as MX, then import the MX data [closed]

I have a very large CSV data file, which I imported it to my active Notebook: ...
user avatar
  • 4,391
0 votes
1 answer
97 views

Import CSV data from internet to mathematica [closed]

This Link has data in CSV format for 2015 and other years. I would like to get the data for 2015 (by clicking on 2015) but the CSV data format has more rows than Excel can handle and therefore the ...
user avatar
  • 4,391
1 vote
1 answer
116 views

Correcting delimiter definitions in .csv files

I have a number of .csv files that have a semicolon (;) delimiter rather than comma, and I'm wondering if there is a simple way to change the text in them all. Lets say I have a test file "a.csv&...
user avatar
  • 941
1 vote
2 answers
96 views

How to import a (large) .CSV file maintaining its shape (defined by curly brackets)

I'm working on large tables generated with Mathematica, evaluated on different computers. I plan on join the tables on my computer and proceed with the interpolation of the data there contained. The ...
user avatar
  • 113
0 votes
2 answers
188 views

Import and extract certain column and row

I have a problem with importing and extracting 2nd column in my CSV file. I need to have 3 list, the first one first column except for first row, the second will be second column except for 1st row ...
user avatar
  • 185
7 votes
0 answers
65 views

Export Strings without quotes to a CSV file [duplicate]

Would like to export a List of Lists to a CSV file. Would like the strings in the exported file to not have quotes around them, which doesn't appear to be the default behavior. Is there an option ...
user avatar
  • 967
1 vote
1 answer
79 views

How to use column header as the x-axis in ListPlot?

I imported a csv file, and the header of the columns are specific dates. How would I plot these points using ListPlot, but the x-axis instead of 1,2,3, etc, is the dates from the column headers? For ...
user avatar
0 votes
0 answers
29 views

Reading CSV data as numbers rather than symbols

I am attempting to read some data from a CSV file I have using edgeDistribution = Import["edge_distribution_2.csv", "CSV"] Mathematica will ...
user avatar
  • 33
1 vote
1 answer
50 views

Formating of cells with Dates on Exporting [closed]

I am trying to export a matrix into a .CSV file which has dates with format: Year/Month/Day. When I try to export it into a CV those cells are converted into Day/Month/Year When I try to export it ...
user avatar
0 votes
1 answer
64 views

Importing a CSV file hangs up [duplicate]

Ver.12.1.0.0 hangs up when I do "Import" a csv file that contain an entry ""000000000000000000000000000000000000000053253943D755066515000057", while this csv file can be read ...
user avatar
0 votes
1 answer
230 views

How to export list of lists to a CSV without "Row[{}]" text?

When I export a CSV file using the code above, I get something like this: I'd like to export the answers / text on the right column without "Row[{}]" but just the raw text. Is this possible?...
user avatar
1 vote
0 answers
41 views

How can I import a txt file with both tsv and csv characteristics and plot it?

I have a problem with importing and plotting a txt data. I used this code: data=Import["C:/Users/user/Desktop/Mohammad Simulation/2nm.txt","TSV"] header=Take[data, {10, 1889}]; But, I am not able ...
user avatar
-3 votes
1 answer
81 views

Reading a excel CSV file [closed]

I have a CSV file with exactly the following data: ...
user avatar
  • 125
2 votes
1 answer
384 views

CSV import with delimiters not working for certain characters (curly quotation marks)

Here's an example CSV file (Example 1): "Text","”","False","False","False","False","0","1","24","0","9","450","450" and the code to import it (Code 1): ...
user avatar
1 vote
1 answer
213 views

Plotting a 2D grid "spectrogram" from a large .csv file [closed]

I'm aware of this question here that uses MatrixPlot to plot the spectrogram of a sound file, but it's too complicated for me to understand, unfortunately. My file ...
user avatar
  • 141
0 votes
1 answer
85 views

Export to CSV gives unformatted output and unexpected characters

I want to export data I collected in a Table to a CSV (or XLSX)-File. However, the output is not very handy, it is not in a column-shape but surrounded by {} and in ...
user avatar
  • 67
2 votes
1 answer
308 views

Importing a csv file yields weird first character

Whenever I import a CSV file, I get this weird character at the beginning of the file ,I am not sure why. How can I avoid this?
user avatar
3 votes
3 answers
3k views

How can I import a CSV file into Mathematica? [closed]

I have a data.csv file in the Downloads folder in my Macbook. I am trying to import the data into a Mathematica notebook using ...
user avatar
  • 131
0 votes
1 answer
125 views

Import many csvs from folder and change date format from american to european

I have many csv files in one folder and I have to import all of them into Mathematica. I need actually just two columns and all the rows except for the first one so I got rid of another 6 columns and ...
user avatar
  • 185
0 votes
0 answers
68 views

Finding area between curves formed by csv data

I have a bunch of Differential Pulse Voltammetry data I am trying to import into Mathematica, and find the area between each curve and the blank. So far I have used the following commands: ...
user avatar
0 votes
0 answers
53 views

Plotting data imported from Excel and overlaying it on a disk

I'm new to Mathematica and I'm trying to get the hang of plotting data from an external CSV file. The data is just x, y, z values from an experiment I ran. I would ...
user avatar
3 votes
1 answer
505 views

How can empty fields in a csv file be set to Missing when importing as a Dataset?

When importing a csv file with empty fields as a Dataset, the empty fields are set to zero-length strings (""). There is an option, ...
user avatar
  • 971
2 votes
1 answer
289 views

How do I tell Mathematica to write numbers on a file without using scientific notation?

I need to write numbers out to a file without using the scientific notation. How do I tell Mathematica to do that? This is the code I am using: ...
user avatar
  • 6,114
5 votes
1 answer
427 views

Huge CSV file with numeric and text data

I try to load a huge CSV file (~ 4 Gbyte), the data is both numeric and textual. So, I can't load the data as a string. ...
user avatar
7 votes
1 answer
5k views

Working with a CSV data file with 100 millions rows (and 30 columns)

I am new to working with large datasets.. Currently I am struggling to upload a "big data" file into Mathematica. The file is in the CSV format and has 14GB. There are 100 millions of rows and 30 ...
user avatar
  • 641
2 votes
1 answer
499 views

How to separate rows with commas in imported CSV

I imported a CSV file that uses commas as its delimiter, but some fields also contain commas. When I import the file into Mathematica as follows ...
user avatar
  • 1,001
7 votes
1 answer
1k views

Import specific columns from a large amount of CSV files

I'm looking to import the 4th column of data from a few hundred CSV files that I have stored in various folders. I have been able to import all CSV files from a given directory through use of: ...
user avatar
2 votes
2 answers
100 views

Convert CSV data for use with CandleStickChart

can anyone show me an example of how to import a CSV file and produce and CandlestickcChart using the imported data. I have tried ...
user avatar
  • 23
6 votes
2 answers
154 views

Importing a string such as "3d456" from a CSV file causes trouble

I have a CSV file I'm importing with Import and it consistently crashes Mathematica. It turns out the culprit is one particular value of an ID field that was ...
user avatar
  • 596
3 votes
1 answer
1k views

Appending to a .csv file [duplicate]

I have a selection of Lists of data which are in the same format, and if I Export them all to CSV at the same time I get a nice ...
user avatar
  • 1,259
0 votes
1 answer
174 views

Import floating numbers from Google spreadsheets in CSV

For some reason when importing some floating numbers, Mathematica does not interpret them correctly. For example this spreadsheet: https://docs.google.com/spreadsheets/d/...
user avatar
  • 1,105
1 vote
1 answer
114 views

separating a `ReadList` of a CSV file into columns using `Case`

I have a really large file and would like to determine the pattern required for separating the columns by the different headers. I attempted to use Cases but it's ...
user avatar
  • 670