Questions on converting data, graphics, sound etc. from Mathematica into other file formats.

learn more… | top users | synonyms

29
votes
4answers
3k views

How do I save a variable or function definition to a file?

Is it possible to save a function which was created via Interpolation of some data in such a way that I can use this function in a new Mathematica session without ...
55
votes
6answers
8k views

Exporting graphics to PDF - huge file

I want to draw some basic surfaces, export them to PDF and include them in a LaTeX file. I create a simple 3D graphics object, for instance with ...
22
votes
1answer
1k views

Does Mathematica support variable frame rate for any video format, in analogue of GIF-style “DisplayDurations”?

The good old GIF animation format allows us to set the duration of each individual frame in the animation separately. This is especially useful if some frames in ...
54
votes
5answers
7k views

$\LaTeX$ and Mathematica

I quite often would like to draw graphics in my $\LaTeX$ documents using Mathematica. I have encountered three problems. I would like to know if there are any workarounds to these problems I would ...
14
votes
2answers
5k views

Is it possible to export the equations from Mathematica to MATLAB?

Is it possible to export the output expressions from Mathematica computations (e.g., equations) in valid MATLAB syntax?
24
votes
2answers
996 views

Saving a notebook as PDF, preserving syntax highlighting

Currently, one may save notebooks as PDFs from the menu by Save As... and then selecting PDF (on a Mac, I imagine it is similar on other OSs). However, the ...
14
votes
3answers
1k views

How can I ensure graphics exported in WMF format don't have text-spacing problems?

A lot of my work involves manipulating data, drawing a pretty plot of it and then inserting that graphic into a report written in Microsoft Word, under Windows.1 The fun comes with the exporting part. ...
17
votes
3answers
3k views

How to export large graphics?

I'm using Raster to create large graphics (1000 by 1666), which I want to Export as a JPEG or TIFF in a resolution that can be printed in a large size, 3' by 5'. ...
18
votes
3answers
2k views

Graphics exported from Mathematica 9 are very large because even standard fonts are embedded

I've upgraded from Mathematica 8 to 9 (which apparently leaves the old version installed and usable which I didn't expect). I see a significant difference in the size of the PDFs produced by 'Save ...
20
votes
2answers
1k views

How to include Mathematica animation in a PowerPoint presentation?

Note: Cross-posted at Wolfram Community I want to include a Mathematica animation in PowerPoint presentation. My code is: ...
20
votes
3answers
2k views

Avoiding white lines inside filled area in RegionPlot exported as PDF or PS

When doing a RegionPlotand then exporting (or saving from the front end) as PDF or EPS, there are small white lines in the filling of the region. Here's an example ...
19
votes
5answers
5k views

Export Plots to $\LaTeX$

What is the quickest and best way to export a plot image from Mathematica to a $\LaTeX$ Editor? Is there something quicker than exporting it to an image and then including it in the $\LaTeX$ document? ...
9
votes
4answers
715 views

Export Graphics[] without white edges

I am trying to generate & Export[] Image with the below code, but as shown in the images I get some white border around my rectangle. How could I export an images that stopes right at the edge of ...
2
votes
3answers
583 views

Trouble with fonts when exporting a 2D-plot to vector formats

I've set up my plot to look exactly how I like it. At least it does so on screen. Upon export though, only the bitmap formats look the same. For PDF and EPS, the FontSize seems to get ignored and the ...
6
votes
2answers
205 views

How to automate generation of image files?

I need to generate a large number of figures as PNG files, and I'm trying to decide whether Mathematica would be the quickest way to do this. All the figures have the same basic structure, and I'm ...
32
votes
4answers
2k views

How well does Mathematica code exported to C compare to code directly written for C?

Essentially what it says in the title. Mathematica can, IIRC, export it's code to C. How much overhead does that inflict on the code, as compared to writing it from scratch in C?
15
votes
2answers
464 views

How to develop an Import/Export converter for Compress[]ed data?

Mathematica has a cross platform data exchange format, WDX. Unfortunately importing or exporting large data from/to WDX is very slow. Using MX files is very fast, but they are not compatible across ...
16
votes
1answer
367 views

How to fix broken InterpolatingFunction?

I have an InterpolatingFunction based on irregularly-gridded data, like this: ...
9
votes
2answers
557 views

Rasterizing a plot make axes ticks invisible

I've evaluated this code: plot = Plot[x, {x, 0, 10}]; g = Rasterize[plot, ImageResolution -> 300]; Everything looks good except the ticks (on the axes); they ...
7
votes
2answers
578 views

Speeding up Import and Export in CSV format

I am handling large numerical data in Mathematica. In smaller problems everything worked fine using Export and Import with the ...
5
votes
1answer
1k views

Plot, extract data to a file

I need to save data that Mathematica uses inside the Plot command. The format that I would like to have is: x1 y1 x2 y2 ..... ...
21
votes
7answers
2k views

Embed Code Into Image

I often export images(plots, matrix, arrays, etc..) from mathematica which I end up putting in word documents or uploading to the web. The problem is that I often lose the original code and I am left ...
20
votes
1answer
2k views

Autorotating 3D plots

These days, I have to produce quite a few 3D surface plots (mostly functions of the type $\rho(\theta,\phi)$ plotted with SphericalPlot3D). To exchange these ...
13
votes
3answers
4k views

How to save animation in mp4 format instead of avi?

I'd like to save Manipulate[] output so that I can embed an mp4 in my pdf document (using the media9 latex package). I've done this successfully in the past by ...
16
votes
4answers
1k views

Printing exported PDF graphics fails (version 8)

When I export even simple graphics, say, a DateListPlot to PDF under Windows, it refuses to print on any of the printers at work. Acrobat (Reader X) throws three ...
11
votes
1answer
539 views

Exporting numbered equations to HTML/TeX using conversion rules

This question is a follow up from this one. It may also be considered a duplicate since I have already asked this question in stackoverflow almost a year ago. For a background on using numbered ...
11
votes
2answers
393 views

Exporting notebook to HTML, using conversion rules

The idea is to export the whole notebook to HTML with all the math equations in latex form. In this way we can add the mathjax script and it will take care of the math. Suppose we have the following ...
3
votes
4answers
2k views

How to export data files using specific format

Very often, I have to export data files from Mathematica. These output files contain several columns and hundreds of lines with data. For the sake of the question let's create a sample list ...
5
votes
3answers
398 views

Avoiding grid lines inside filled area in RegionPlot exported as PDF

Basically the same question as here, but now with regions which have opacity. ...
5
votes
4answers
834 views
3
votes
1answer
204 views

Exporting lists to files

I am trying to write a program which will generate a list of objects and then exports it in a separate file and clears its memory. As an example I tried the following ...
34
votes
1answer
530 views

Export Code to Pseudocode?

I'm writing a paper and all my code is in Mathematica. The snippets are mostly simple, and consist of loops, maps, variables, and conditionals. I'd like add it to my paper, however, not many academic ...
25
votes
3answers
2k views

How to embed fonts when exporting Mathematica graphics as PDF

Upon exporting a Mathematica graphics expression as a PDF, Mathematica does not seem to embed any nonstandard fonts used. When you open the resulting PDF document with a PDF viewer, all the text items ...
16
votes
2answers
1k views

How to save all data in all variables so that loading it is fast?

I've got this CSV file I've imported that has tens of millions of lines in it. It takes around 20 minutes to import. I've been working with it for a while and have the processed data spread out in a ...
10
votes
3answers
460 views

How to make Mathematica graphs in Microsoft Word independent from Mathematica?

When I open a .docx file containing Mathematica graphs on a computer without Mathematica software installed, the graphs look corrupted. For example, ...
15
votes
2answers
196 views

Graphics elements do not line up perfectly in exported PDFs

Graphics elements do not always line up perfectly in exported PDFs. Take for example ...
19
votes
1answer
450 views

Convert Graphics3D containing BSpline to polygon primitives for export to 3DS?

Graphics3D[] objects created with BSpline functions will not export to 3DS format, which only supports the more basic primitives. Is there any straightforward way ...
16
votes
2answers
485 views

Exporting a dashed plot with a color gradient to a vector graphics format ruins the dashing

When exporting a dashed plot with a color gradient to a vector graphics format such as EPS or PDF, the dashing is partly ruined. For example, this command: ...
10
votes
1answer
415 views

Automating FTP upload within Mathematica?

I have MMA-generated html and would like to automate uploading to a named directory to a web host via SFTP or HTTP POST, ideally without creating local temp files. The closest question I could find on ...
5
votes
1answer
354 views

Exporting a 3D plot into a 3D viewing format and axis scaling

I've been trying to export a Plot3D into an X3D (JVX, VRML) file using the Mathematica's Export function. The problem is that when the PlotRange is large compared to the other two dimensions the ...
10
votes
1answer
256 views

How to work around incorrect tooltips in plots exported to HTML

This is an issue that I always wanted to investigate but haven't gotten around to solving yet: The tooltips for contour lines in a plot like this can be very useful in the Notebook interface: ...
7
votes
1answer
904 views

Get the coordinates from ContourPlot and RegionPlot

How do I get the coordinates from a contour plot I've done in Mathematica? For example, I have a two-variable function f[x, y], for which I can make a contour plot: ...
7
votes
1answer
352 views

How can I use “Save as (html)” and still render code as text?

I use notebook "Save as ... (html)" to convert my .nb to web. Formulas and plots get converted to images, which is fine. But code (input cells) get converted too into images. I would like people to be ...
7
votes
2answers
677 views

Is it possible to export a graph as graphic to Excel?

It is straightforward to export lists to Excel with Export. Can I export a graphic image, too? This does not work: ...
6
votes
2answers
1k views

Export animation of a Manipulate autorun sequence?

I've got a Manipulate that does a vector field plot. Basically a function that returns a list of Graphics objects and a couple of sliders: ...
6
votes
1answer
687 views

Formatting output of OpenAppend[] to match what Export[data,file,“.csv”] would output?

I have a large data set that gets exported to a .csv file. Export[data,filename,"csv"] is extremely fast and formats the data in a nice JMP-friendly manner. ...
11
votes
2answers
1k views

How to dynamically name and date a file for export?

I have various functions that export Excel and text files, and need to have them named with a name based on the content of some variables in the function and the time and date. How can this be done ...
8
votes
1answer
481 views

Why does Export drop namespace prefixes in the exported XML file?

I am trying to generate an Excel-compatible XML file from Mathematica. First, I created a test XML file by saving a Microsoft Excel workbook as "XML Table". Then I ...
6
votes
1answer
216 views

How can I scale a plot in vector graphic or PDF form?

I am not at all a computer graphics expert, but it seems that portable document format (PDF) files have a "native size," even though they may (and usually do!) contain vector graphics that can be ...
5
votes
1answer
959 views

Combine multiple PDF files into one document

I have multiple single page PDFs I'd like to join together into a single file. (Obviously I mean the file format and not the probability distributions here!) I'm aware of free online services such as ...