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

learn more… | top users | synonyms

0
votes
0answers
12 views

How to export a matrix (Mathematica 8)?

I would like to export the object type: { {{"a", "n", "y"}, {"a", "s", "k"}}, {{"b", "y"}}, {{"d", "a", "t", "e"}, {"d", "a", "y"}, {"d", "r", "y"}} } and then import this object. It has to have the ...
1
vote
3answers
50 views

Import Data using selection criteria

I imported a file (text and numbers) and made constructed this. e[[1,All,{1,2,3,4,6}]] Column 1 is the name of the state. How can I get a subset of this where, say Column 1 is not equal to "New ...
19
votes
1answer
1k views

Web Browsing Automation with Mathematica

I want to build a bot to automate web browsing, this mean something like: filling forms press "submit" buttons find certain text inside pages and so on... How can I do this with Mathematica? The ...
11
votes
3answers
236 views

ToExpression fails with long nested string expressions

Consider the following conversion from String to Mathematica Expression: ...
1
vote
0answers
19 views

Import/Export a FIT file, Fitness file created by Garmin GPS's and others

A FIT file is a binary replacement for GPX and TCX text files containing GPS and fitness data (heart monitors, etc.). Mathematica reads GPX and TCX files and represents them as XML. I would like to ...
4
votes
1answer
70 views

Is it possible to move .mx file from one server to other?

I have mathematica file in one server along with .mx file. Is there any way to move the .mx file from one server to other such ...
2
votes
1answer
60 views

How to get a audio file's duration time in Mathematica?

I have a *.avi file and if I want to know the file's duration time: I can use this code to get the result: Import["test.avi", "Duration"] or the code to get the ...
15
votes
4answers
3k views

Cut and paste data from a spreadsheet

I have a set of data points in two columns in a spreadsheet (OpenOffice Calc): I would like to get these into Mathematica in this format: ...
7
votes
1answer
208 views

Assign the contents of a “Copy” operation programmatically to a variable?

While an earlier question Cut and paste data from a spreadsheet nominally addresses the issue, a year has past since its OP asked it and I hope that others have come across simpler or more direct ...
2
votes
4answers
2k views

Plotting a large number of data points

I would like to know how to plot when I have a large number of points (arround 600) in a specific format: ...
2
votes
3answers
226 views

Import data from first/last 100 rows of a file

If one wants import data from the first three rows of a file "myfile.data", one can use the command Import["myfile.data",{"Data",{1,2,3},All}]; However, if I ...
1
vote
2answers
54 views

Table operation after export and import of data does not give me the same result

If I create a table of this kind: (m1 = Table[{RandomInteger[], RandomInteger[{1, 5}, {3}]}, {i, 1, 5}]) // MatrixForm which looks like I know how to pick ...
1
vote
1answer
45 views

List Manipulation and Removing Cases

I've imported a large data set, manually removing headers in the .rtf file where it originates. However, when I import this data, I receive this output: ...
4
votes
0answers
82 views

ImportString JSON possible bug

My problem is when I catch up some json output of whatever method and process it with ImportString[%, "JSON"], The first time ...
1
vote
2answers
55 views

Save file from URL using mathematica

Is there an easy way to download and save a .zip file from a URL to my computer through Mathematica? I am trying to develop an auto-update function for a mathematica package that is distributed via ...
0
votes
1answer
39 views

Elegant ways of solving this file batching task

There are a batch of data files in a folder (dir = "D:\\Documents\\datadir"), each of which consists of a list of data items, one per line. Each data item is a pair ...
59
votes
3answers
5k views

Recovering data points from an image

Unfortunately, some data can only be obtained in picture form (Japanese publications anyone?). Since this cannot be worked with, it has to be converted to a dataset that can; I was wondering whether ...
35
votes
5answers
4k views

How can I extract data points from a black and white image?

Consider the following graph (source): Is there any way to extract the data points from this image in a semi-automatic way? I have seen, and tried the methods suggested in this question, but they ...
4
votes
1answer
110 views

How to use RunProcess to import external function?

I have a functions written in an external language called GO. How can I quickly load them into the kernel for use as Mathematica functions? The two ways I've tried are with MathLink and LibraryLink ...
0
votes
2answers
51 views

File Handling. How to save the progress in a file?

Assuming I already have the file created. I have a programme that,returns an output, in our case number. I want Mathematica to save this number in a file, together with results saved from previous ...
8
votes
4answers
615 views
1
vote
0answers
40 views

Inport a web page with latex code as image png or other

To be brief; I would like to import a web page, then I write Import["http://fabricebaudoin.wordpress.com/2012/10/25/lecture-32-the-malliavin-derivative/"]; which give a notebook file without png ...
16
votes
1answer
523 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 ...
0
votes
1answer
70 views

how to read an excel file using mathematica? [closed]

I have to do some data analysis and i have data in an excel file. Please tell me how to read an excel file in mathematica.
3
votes
1answer
113 views

Efficiently reading CSV with ReadList

I have a large CSV file (~1gb) with mixed data. Basically with strings and integers. It takes very long to import this whole dataset with Import[] so I would like ...
4
votes
1answer
149 views

CSV vs XLS for import

I need to import data from various database sources. At the moment I plan on importing files via a CSV file or XLS. All the data if in XLS would be on one sheet (notebook). Are there any advantages ...
4
votes
0answers
89 views

Import Excel data forcing links (ie workbooks) to be updated

We have noticed importing data from an Excel spreadsheet doesn’t update links. The problem with this is if you import a spreadsheet that comprises of linked workbooks data and those workbooks have ...
7
votes
3answers
569 views

Skip header lines on import

When importing a data file what are the comment symbols for Mathematica? That is, given a file like this blabla bulbul 1 2 6 54 7 ... .. what symbol do I have ...
1
vote
3answers
153 views

How to import files with headers?

R has excellent header supports such as read.table with header options. I don't want to mess up with text-processing or stream-processing. I am looking for a similar tool as in R because it saves a ...
6
votes
1answer
175 views

Incorrect result while using SemanticImport for CSV file import

I might use this incorrectly. I want to use a .csv file that (as list) looks like: ...
1
vote
0answers
125 views

InstallJava::fail error when importing an image with a Raspberry Pi

I'm trying to import an image in Mathematica on my Raspberry Pi. The code is simple but I get an error when importing: ...
3
votes
1answer
50 views

How to make Import recognize a new file extension? [duplicate]

I've written an import converter for a custom file format, and it all seems to be working as expected, except for the fallback behavior with no arguments: ...
35
votes
8answers
4k views

How do you convert a string containing a number in C scientific notation to a Mathematica number?

Suppose I have a string containing the C-representation of a floating point number, for example s = "1.23e-5" and I want to convert this to a Mathematica number. ...
1
vote
1answer
47 views

Importing file as a string causes a puzzle

I generate simple txt file and import it as follows: a = Import["binary.txt"]; b = Import["binary.txt", "String"]. It appears then that lengths of imported strings ...
1
vote
2answers
58 views

Why can't I import a file in the init.m file?

I would like to have some data read in every time the kernel starts, but it doesn't seem to work. Say I have a CSV file I want to have read in, for example I use: ...
0
votes
0answers
26 views

Importing large arrays and releasing memory

I am trying to import huge 3 dimensional arrays (in my case approximately 2GB) which I calculated before and saved in .MX format. Then I want to work with a smaller ...
4
votes
1answer
100 views

HDF5 and complex numbers

I "Export" an array with complex numbers with HDF5 format. When I "Import" it, I only get the real part. Simple example: ...
1
vote
1answer
294 views

How to work with 3D images of STL format

After importing a 3D image of STL format, my possibilities in regard to "3D Volumetric Image Processing" seems rather limited. All examples are given with TIFF files. Is there a way to convert from ...
1
vote
0answers
34 views

SemanticImport::unexpinvaliderr error when using trial version

I am trying to use SemanticImport for a personal experiment. I can correctly import a tsv file from a path, but if I change ...
3
votes
2answers
168 views

Mathematica data structures for analysis [closed]

I'm starting to learn Mathematica and one thing that has been bugging me is the apparent lack of a good structure for keeping data and metadata for analysis. Something along R's ...
5
votes
1answer
169 views

How can I read compressed .Z file automatically by Mathematica?

When I read .Z file by something like jpldatstring = Import["ftp://cddis.gsfc.nasa.gov/products/jpl/2003/jplg0040.04i.Z"] Unfortunately, it turned out that ...
11
votes
2answers
665 views

How to build a bvh player in Mathematica?

How to build a bvh player that can be used to visualize human motions in Mathematica? Any idea or sample code would be appreciated. ...
2
votes
4answers
107 views

Finding relevant parts in XML document

My qyestion is about a XML document and finding parts of strings. test = Import["C:\\Users\\filename.xml", "XMLObject"] This gives the following output: ...
1
vote
0answers
35 views

How i can extract a single layer from a SHP file? [closed]

I just import a SHP file that have a series of layers, how can i get just one if i know the name of it?
3
votes
0answers
61 views

Monitor progress of ZIP file extraction

Importing a ZIP file containing potentially many individual files in a (custom) format using Import[filename, {{"*"}, "Gaussian"}] takes quite a while. How can I ...
0
votes
0answers
50 views

Visualization of 3D data by Raster3D and Import

I would like to visualize data stored in an external .txt file. The data is a 3D array of real numbers. I would like to visualize the data by using Raster3D function, but I am not sure what is the ...
0
votes
0answers
31 views

LinkObject::linkd error when reading PDF file

I'm attempting to import a PDF file into the Wolfram Desktop (though I have also used Mathematica 10 with identical results) on a Mac running OS X 10.9.4. The ...
0
votes
3answers
95 views

Importing multiple files with a loop

I have 101 files with data that I want to import into Mathematica. All the file names are numbered as follows datafile.20.0000.out, datafile.20.1000.out, datafile.20.2000.out and so on. I used the ...
14
votes
3answers
464 views

How to Import random elements of huge data files

I am calculating huge data files with an external program. I would like then to import the data into Mathematica for analysis. The files are 2 columns and up to many millions of rows. So for ...
2
votes
1answer
60 views

Customized directory import

I have defined a function in a package to import some data files under a directory which is produced by a scanning device (LS55): ...