Stack Exchange Network

Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [import]

Questions about getting data, files, images etc. from various formats into a form that can be read, tranformed and manipulated by Mathematica

1
vote
1answer
8 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, ...
2
votes
1answer
78 views

Importing Data multiple times from the same File

I have a large data file (.txt) with bivariate data in the following form x1,y1 x2,y2 x3,y3 . . . xn,yn ---------F 0 x1, y1 x2, y2 . . . xn, yn --------F 1 . . . ...
0
votes
0answers
32 views

Unable to import an .eps file

I am trying to import an .eps file into Mathematica, but I am getting an error. I tried this ...
8
votes
1answer
139 views

Scrape AJAX Website with Webdriver

I hope the new Webdriver functionality can help as the normal Import and HTTPRequest don't work. The sites I have found are a ...
7
votes
1answer
188 views

Import data from dynamically generated webpage

I'm trying to get data from a web-page data=Import["https://stats.nba.com/team/1610612738/traditional/", "Data"] It returns only a textual information. ...
2
votes
1answer
92 views

Deleting missing values from a dataset

I wanted to create a dataset of all UFO sightings in April of 2018. The AssociationThread doesn't want to work, because some of the entries are missing value, what ...
1
vote
1answer
32 views

How to import XLSX data as integers?

I am importing simple 0s and 1s array from Excel myDep = Import[ FileNameJoin[{NotebookDirectory[], "dependencies.xlsx"}], {"Sheets", "Data"}] All good ...
2
votes
1answer
66 views

Import columns from a long .txt file

I have to import columns 1,2,3, and 6 from a long (2 * 10^5 rows) file with this structure: ...
22
votes
0answers
676 views

Getting EPS imports to respect the original fill rule

One major problem in my attempt to answer to the CountryData flags question is that the way Mathematica handles filled curves differs from the way SVG and EPS style editors do. The latter two have the ...
4
votes
0answers
46 views

Importing and and manipulating large GEOJSON files based on geographic locations

I have large GeoJson data files that I would like to import (i.e. buildings in a city, see image below for data structure) and then "cut out" only the buildings that are within approx. 100 GeoDisks (...
2
votes
1answer
49 views

Web Scraping - Why are these numbers interpreted as strings?

I started with: data = Import["https://www.destatis.de/DE/ZahlenFakten/GesellschaftStaat/Gesundheit/Todesursachen/Tabellen/Sterbefaelle_Unfaelle.html", "Data"] ...
10
votes
3answers
1k views

Import tweets from Twitter

Robert Raguet-Schofield in the Mathematica Blog introduced a way to import tweets from Twitter into Mathematica. I attempted to use this method. I started with this line of code: ...
0
votes
1answer
43 views

Export and import sound give different data

If I export a sound object and then I import the same sound I have a different data array. The errors seem to have a certain regularity. They are all multiples of the same value: Why does it ...
1
vote
0answers
31 views

Export system of inequalities in MPS format

I am interested in the .MPS format, usually used in Linear Programming problems (see here). When importing a file in the .MPS ...
1
vote
1answer
88 views

How to get URL request response in Mathematica?

I am considering the following link: https://myimmitracker.com/en/ca/trackers/consolidated-e-apr-tracker-express-entry-permanent-residency-application It produces the following page with a table in ...
3
votes
0answers
101 views

How to import a binary data generated by Fortran? [closed]

I have a unformatted binary data file generated by gfortran. However, when the binary data is imported by Mathematica, a correct result is not obtained. This is my fortran code: ...
1
vote
2answers
70 views

What info is exchanged when using Import[url]?

When using Import with a url what information is broadcasted/sent to the receiving end of the request and is it possible to monitor/modify that information?
1
vote
2answers
35 views

Import date and number Matrix Formatted as text

Hi I am new to Mathematica. I have a large text file that looks like: {"i":"2008-02-22","v":"9.102"},{"i":"2008-02-23","v":"11.14"},{"i":"2008-02-24","v":"12.21"}.....
3
votes
0answers
48 views

How to import unsupported language dictionaries?

Mathematica seems to only know about these 27 languages: However, I need access to dictionaries for other languages, namely Romanian and Japanese. Now, WordList ...
1
vote
2answers
70 views

How can I extract blocks of 8 bits data from a plain text file?

I have a plain textfile consisting of 4M numbers (0 and 1's) from the number Pi. I would like to split this textfile into blocks of 8 bits (ie 8 characters). I know this can be done with StringTake ...
0
votes
1answer
130 views

Package to read in data from excel files

I want make a package to add a function to Mathematica that reads all excel files is the working directory that is set after the package is loaded. ...
1
vote
2answers
75 views

Importing Excel File as Dataset

This might be a basic question but I couldn't get it to work. I have a dataset in Excel that I import to mathematica using ...
3
votes
1answer
78 views

Memory consumption problem when reading png images with Image`ImportExportDump`ImageReadPNG

For importing png images I use often: image = First@Image`ImportExportDump`ImageReadPNG[fileName] (see: ?*`*PNG*) since this is faster than: ...
3
votes
1answer
55 views

What's the best way to import such dataset?

https://www.ocr.org.uk/Images/400305-large-data-set-lds_1-h630-2018-h640-2018-2019-pre-release-data-mei.xlsx What's the best way to import such dataset? I have tried to use ...
3
votes
1answer
78 views

Using Mathematica to read .HDF (not .HDF5) metadata?

I am obliged to work with existing .HDF files. These contain metadata essential to my research that Mathematica (latest version) appears unable to access. Metadata listed on https://reference.wolfram....
4
votes
0answers
53 views

Is this the most idiomatic way to convert matrix into dataset?

Is this the most idiomatic way to convert matrix into dataset? (for Mathematica 10 or higher) I was kind of hoping this would work: ...
2
votes
1answer
98 views

Mathematica incorrectly imports a table

I am trying to calculate the eigenvalues of a large matrix (10^4x10^4), which is formed by summing a matrix containing advective terms and a matrix containing diffusive terms. I am using the following ...
1
vote
1answer
37 views

Programmatic access to Export options for filetype

For specific filetypes, e.g JPG, GIF, etc. I would like to get a list of available options for use in Import and Export. Unfortunately, the obvious thing doesn’t work: ...
2
votes
1answer
34 views

Import files AppendTo and ToExpression

I have a list of files all indexed as filename1,filename2,filename3,... up to 50, all in the same directory, and I wanted an ...
4
votes
4answers
532 views
2
votes
0answers
28 views

Problem Importing Multiple `.wls` Files From Parent Directory [closed]

Inside a Wolfram Script file, I'm trying to import another .wls file that's in a parent directory. More specifically, I'm trying to import ...
-1
votes
1answer
118 views

Importing large csv files [duplicate]

I'm trying to import a large csv file (around 1.5GB) so I can multiply one of the columns, and plot it against another. There are seven columns in the file when I try and open it in excel, and I need ...
3
votes
1answer
153 views

Open a hdf5 file in SWMR (single writer multiple reader) mode in Mathematica 9.0?

I'm running an experiment where I want to be able to save my data to HDF5 on a shared network drive on one computer (using python and h5py), and be able to read it and do analysis while it's running (...
27
votes
2answers
5k views

How to programmatically extract mathematical formulas from Word with Mathematica 9?

I have a bunch of(1000+) Microsoft Word document in .Docx format. How can I programmatically extract the mathematical formulas from MS Word using Mathematica 9? This is what example looks like (or ...
1
vote
1answer
41 views

import list of lists list-wise

I produce several times automatically a number of different lists of varying length and structure like: ...
10
votes
1answer
97 views

Creating image layers and saving to pdf

In Adobe Illustrator (and other such graphics programs), it is possible to place different objects on different layers. All objects on a layer can be edited together, their stacking changed, and other ...
3
votes
2answers
59 views

Is there a straightforward way of naming CSV/TSV columns when importing as a dataset?

I have data in TSV (tab-separated) files. The thing is, columns do not have headers. Importing data is as easy as ds = Import["foo.tsv", {"Dataset"}]; ...
7
votes
0answers
92 views

Problem to import numbers longer than 19-digit with “JSON” or “RawJSON”

MMA 11.0.1.0 (Windows 10, 64-bit) I see that "JSON" import can be buggy (154245), so my question is simple: can the following behaviour be repeated and, if so, is it a bug? (excuses if I've missed ...
4
votes
1answer
35 views

Importing the text from paragraph elements within a specified division

I'd like to import plaintext found within paragraph blocks nested anywhere inside certain div's. Here's a page to try it on: ...
3
votes
2answers
85 views

Importing an Excel file as a structured dataset

I need to import an Excel file as a dataset with row and column headers, and the following option using "Dataset" does not work. However, I can import the Excel file using "Data" option as a list ...
2
votes
2answers
58 views

Using list of rules from imported .mat file

I'm attempting to learn Mathematica to replace MATLAB. However, I have some data in .mat files which contains named variables. Whenever I import the .mat file, I get a list of rules. What's the best ...
0
votes
1answer
79 views

Get .csv or .xlsx real data, some missing, into Mathematica and form it for curve fitting and 3D plotting

Problem: My data consists of Real values at Real $x, y$ positions. It is stored in the array-forms: comma-separated (type .csv) and spreadsheet (type .xlsx). As a Mathematica Dataset, it may be ...
1
vote
3answers
77 views

How to import a CSV file of files that have space delimited values?

I've received a data file in a mysterious ".pos" format. It consists of many lists that are separated by the space character; these are in turn separated by commas,e.g., { {a b c},{d e f},...} ...
0
votes
0answers
30 views

interface problem for image recognition

I made the following code that should recognize the image imported from the pc. If I do it for the first time it's fine, but if I load a second image it leaves me the name of the previous one. You ...
0
votes
0answers
14 views

Import all images of a folder on mathematica [duplicate]

How can I import all the images of a folder on mathematica specifying the category of such images? For example, if I have a folder with images representing the night how do I import them and specify ...
2
votes
1answer
57 views

Importing a raw image

I have raw images that I can import and view with ImageJ. They are the output of a program which I don't have the source code for, so I'm stuck with the output format. They are imported as follows ...
1
vote
0answers
47 views

Importing and evaluating text file [closed]

I appologise in advance if this was asked before, but I couldn't find the answer. I have a huge amount of data collected in several lists that I need to analyse. I don't want to have all this data ...
1
vote
0answers
70 views

Cannot import data as NetCDF

This might be obvious but I cannot import a dataset. Import["data.nc", "Datasets"] returns {"longitude", "latitude", "time", "time_weights", "date", "aet"} ...
2
votes
1answer
51 views

How do you upload text from a PDF using FormFunction?

I can import text from a PDF using text = Import[filename, "Plaintext"]; I'd like to do the same thing using FormFunction, but am unsure how. I've tried the ...
2
votes
0answers
62 views

Import specific range of Google spreadsheet

I am trying to import only a specific range of a Google spreadsheet as data in Mathematica for further usage like plotting. So I tried to use the data = Import["https://...", "Data"] function, but ...