{matlab} is a high-level scientific programming language with JAVA based interactive environment that enables you to perform computationally intensive tasks as done with traditional programming languages such as C, C++, and Fortran. Its full form is MATrix LABoratory as it uses matrix (linear ...

learn more… | top users | synonyms

1
vote
0answers
33 views

Matlab plots not visible in Latex when saved as jpg

I have to put my plots of MATLAB works in LATEX but my problem is that they are not so clear , is there a way to overcome this problem ?
1
vote
0answers
33 views

Why ps2pdf changes colors of my .eps file?

I'm currently using Matlab R2012a + Inkscape 0.48 + Texlive 2014 + Texmaker 4.4.2 (W7 64) to produce my scientific documents... Basically I create figures in Matlab, export them in .eps, edit them in ...
0
votes
1answer
36 views

Figure imported from Matlab to Latex [duplicate]

I have a problem getting a figure from Matlab into Latex. I have saved the figure as a EPS-file in the same folder as I have saved the latex-documents. This is what I wrote in Latex: \begin{figure} ...
0
votes
0answers
40 views

Matlab 2d/3d figures into LaTeX

I'm writing a paper in LaTeX and want to include some figures from Matlab. I have 2d plots and 3d surfaces to include. Are there any guides to academic writing / published papers which show best ...
4
votes
0answers
31 views

how to support the special latex characters in Matlab plot title [duplicate]

I'm trying to type \digamma. In latex, this character is supported in \usepackage{amssymb}. In Matlab, I can set the interpreter to be Latex as follows Figure1=figure(1) ...
2
votes
1answer
198 views

Use Matlab 2014b figures (via Inkscape) in pdfTeX

I know there are many threads related to this topic, but I still could not find a satisfying solution. Summary Matlab 2014b figures -> export as .eps or .svg -> load into Inkscape (problem is in ...
2
votes
0answers
35 views

Misaligned text strings in pgfplots with view option set [closed]

Please see this post for more background. The problem is that tick mark labels explicitly specified by code of the form: text(x(k),y(k),labs{k},'horizontalalignment',horizk,... ...
1
vote
1answer
75 views

Make visible node text outside of pgfplot axes range

I'm using matlab2tikz in order to generate pgfplots .tex code to create a figure with pdflatex. The matlab function I'm using to create the figure creates each of it's tickmark labels explicitly, so ...
1
vote
0answers
35 views

plotting matlab trisurf and trimesh in latex

I am trying to plot some data in latex. In Matlab the plots are generated by using the function trisurf and trimesh. What is the best way to generate or to import these plots into a latex document ...
4
votes
1answer
179 views

Is there a way to draw a Voronoi diagram with pgfplots?

I want to draw a voronoi diagram with pgfplots, but sadly I cannot get it the way it should look like. I used the Matlab command to get the x and y coordinates and saved them as a dat-file. In that ...
0
votes
0answers
86 views

Fail to convert .eps format file to pdf in a text

I use the following code to export a figure from matlab in .eps format(MATLAB code): my_figure = figure plot(x,y) print(my_figure,'-depsc','Figure.eps') Later I use this code to create a figure in ...
2
votes
1answer
79 views

MATLAB output into tex

Is there any way to import raw MATLAB output into .tex documents? I have already seen verbatim package as a solution, but it does not meet my demands for 2 reasons: Matrix elements are not aligned, ...
0
votes
1answer
103 views

How to insert matlab code with listings?

You know that Matlab save .m file with ANSI encoding. I have a sample .m file, and want import it to Latex with UTF-8 encoding. How to convert ANSI file encodifg to UTF-8 and input it, without ...
3
votes
1answer
236 views

I want to take a CSV file, process the data, and generate a report file, where can I go to learn how to do this?

I have access to MATLAB for data processing, and TeXstudio for the report. I am familiar with MATLAB about 100x more than LaTeX. The data flow I am trying to create: CSV file is generated with 50 ...
6
votes
1answer
115 views

What is the difference between \usepackage{mcode} and \usepackage{listings} for MATLAB codes?

I know there is available in the MATLAB Central File Exchange site the mcode.sty package, which allows to put MATLAB codes into TeX files. ...
1
vote
0answers
55 views

auto-pst-pdf not working [closed]

I have used laprint within matlab to generate a simple graph: set(0, 'defaulttextinterpreter','none') figure(1), clf plot([1 2]) ylabel('A straight line') laprint which gives me line.eps and line ...
0
votes
0answers
20 views

matlab2tikz not capturing subplot borders

When I change the subplot x-axis limits in Matlab and then use matlab2tikz, the subplot border is deleted as shown in the following figure: I have to generate many figures, so is there a way to do ...
2
votes
2answers
228 views

Root locus plots using LaTeX

On my homework, I need to create a root locus plot. Wondering if anyone out there has good suggestions for a package that is able to create root locus plots, or a general plotting package that is ...
8
votes
1answer
349 views

How can I typeset Julia code with the listings package?

I'd like to typeset some Julia code, syntax highlighting and all, with the listings package. For information, the Julia language is a strong contender for MATLAB, and is free and open-source. ...
6
votes
2answers
368 views

How to draw 3d vector field on a line?

How to draw 3d vector field on a line? I want to visualize the vector field $( m_x(x), m_y(x), m_z(x) )$. After searching "visualize vector field", I find that most plotting software either plotting ...
2
votes
2answers
197 views

Choosing lines from a Matlab file using matlab-prettifier

I have been using the matlab-prettifier package a couple of times. So far I have only imported the entire .m-file to be shown in my documents using: \usepackage[numbered,framed]{matlab-prettifier} ...
3
votes
1answer
117 views

Problem with plotting 3d plot in Latex, I have a sample Matlab plot

I have a Matlab plot shown below which I want to replicate in Latex. The data for Matlab is: i_whole=[ 0 0 0 0 0 3.7000 3.8000 3.8000 4.2000 3.7000 ...
2
votes
2answers
491 views

epstopdf error: /undefined in uageLevel:

I try to run: C:\Users\Oleg\Desktop>epstopdf.exe test5-reference.eps and I get just an a blank .pdf with the following: Error: /undefined in uageLevel: Operand stack: Execution stack: ...
3
votes
1answer
92 views

Why do minus signs vanishes in listings typeset with matlab-prettifier? [duplicate]

I am typesetting my MATLAB code with package matlab-prettifier. However, the - sign are gone. How can I get it back? MWE \documentclass[12pt]{article} % For MATLAB code ...
2
votes
1answer
138 views

axis alignment for 3D graph using matlab2tikz

I am trying to include multiple 3D figures (created in matlab) into a latex file. The original 3D figures in matlab look like this: In the .m file that creates these figures, I use ...
1
vote
1answer
129 views

How to avoid Greek letter symbols in lstlisting

I am using the lstlisting package, but I don't want it to show Greek letters by its symbol. For example: \begin{lstlisting} Parameter.delta_x = 0.002e-6; \end{lstlisting} I want that line ...
3
votes
2answers
360 views

Read integers from external data file to document programming code in LaTeX

I am attempting to document my MATLAB programming code in LaTeX. For this, I use the mcode package, which defines the MATLAB lstlisting environment. With the commands ...
1
vote
1answer
78 views

Turning off/on numbering when using mcode

I have an appendix with a full Matlab script, quoted verbatim, numbered and coloured as I want. However, I want to quote about 10 lines of it as a figure in the body of my report, and since I will ...
0
votes
1answer
131 views

How to force wrap MATLAB code

I'm including a MATLAB script as an appendix in a report I'm writing, I'm using mcode to import it, but some of the lines are longer than the width of my paper. In my master document I have: ...
7
votes
2answers
253 views

Adding styling to LaTeX produced by MATLAB

MATLAB has a function called publish which has the option to export a script and its output as LaTeX. It looks quite nice, although there are a few additional things that I would like to do to the ...
4
votes
1answer
258 views

What can I do if a listing is too wide to fit in my two-column document?

I am writing a IEEE document with a LaTeX template I downloaded from the IEEE webpage. I inserted some MATLAB code into the document through the mcode package. It looks something like this: ...
10
votes
2answers
390 views

How can I hide (or blur) some code in a listing?

I have a code listing to write in a report, but I'd like to blur or hide some code parts with a colored box (of same length as the hidden text), so that readers cannot see the hidden parts. (Another ...
2
votes
2answers
325 views

doing 3x3 subplots with the colorbar located northside

I wanted to have my nine (2d) matlab plots shown as 3x3 subplots in latex with the colorbar located northside. I have no idea how to do this especially that I have the colorbar saved separately from ...
2
votes
0answers
228 views

using sublime 3 to install matlab-prettifier package from ctan library [closed]

How do I use Sublime Text 3's built in package manager to install packages from ctan? I am trying to install and use matlab-prettifier in a latex document class report. I manually downloaded, compiled ...
0
votes
0answers
209 views

matlab2tikz not maintaining subplot dimensions

The following Matlab script gives me the two plots of the time series object T204 a1=subplot(3,1,[1,2]) plot(T204) a2=subplot(3,1,3) plot(T204) It looks like this in Matlab: Then I use ...
7
votes
2answers
360 views

Plot and imagesc (from Matlab) with PSTricks

I'd like to plot with PSTricks some data from Matlab. I usually plot these data using the imagesc and the colorbar in Matlab, but I'd rather do it in LaTeX... Here is the picture I want to plot in ...
0
votes
1answer
381 views

Best practices for using MATLAB images in LaTeX?

I am writing a paper currently using PDFTEX, and I make heavy use of MATLAB figures. The problem is that when I make a MATLAB figure, I can adjust it to any size, before saving it. When I save it, I ...
2
votes
1answer
721 views

Problem with xticks when importing Matlab figures using matlab2tikz

When importing the following figure using the Matlab2Tikz, I obtain the following output , with the xticks strangely exported . Does any one have an idea how I can prevent this? Maybe by passing ...
1
vote
1answer
206 views

Matlab2Tikz Error with userdefined matlab colors

I try to include from matlab exported (matlab2tikz) tikz files into latex, but get error messages if i don't use matlab default colors. I don't get the problem?! Thanks you guys in advance Error: ...
2
votes
1answer
275 views

MATLAB Plot Alignment in latex

I have two plots in which the x-axis are the same and I'd like to have the y-axis positions to be aligned. As the numbering of the y-axes are different when I print them in MATLAB as two eps files, ...
2
votes
1answer
177 views

How to programmatically coax pgfplots to recognize nan within surface as matlab does

I came across this post after wondering why nan's did not appear to be handled by pgfplots as they are by matlab when working with the matlab pcolor function. My typical workflow in this context is: ...
3
votes
2answers
207 views

Listings problem with quotes in a string

A single quote occuring inside a listings string seems to be interpreted as ending the string. Is there a way to avoid this from happening? \documentclass[12pt]{article} \usepackage[top=0.3in, ...
2
votes
1answer
234 views

Plotting .dat file

I'm looking to plot a simple plot with data I've taken from MATLAB in a .dat file format. The file has two columns in the order shown below. I would like column 1 to be x and column 2 to be y. I've ...
1
vote
0answers
355 views

Importing plots from MATLAB to LaTeX

This is my first time trying to import plots created by MATLAB into LaTeX and it's not turning out very nicely. I have saved my MATLAB plot as a .png file here and an .eps file here. Using the .eps ...
4
votes
0answers
143 views

eps import wrong title in graphic \pi looks like \neq

Need to import a figure from Matlab. I export it as an eps and use epstopdf to import it in latex for some unknown reasons the greek pi in the title of the plot that looks ok in the .eps does not ...
4
votes
3answers
367 views

How to get listings to print only the header of a Matlab file?

How to extract the first line of a simple matlab file and the following lines just after that begin with the character % ? The number of lines to extract is unknown. Then I want to use listingsutf8 to ...
4
votes
2answers
223 views

clash between mcode and scrbook

I want to include Matlab code in my document. The mcode package used to do a great job in combination with my scrbook document class. However, I recently updated my KOMAscript family to version 3.12 ...
2
votes
1answer
1k views

Matlab->plot2svg->Inkscape->pdf+latex->includesvg = slow rendering pdf + large file. How to solve that?

I have the following workflow. I use matlab to produce 3D plots with transparency and I want to use the workflow of setting the text inside the figure in latex. I am using Texniccenter and MikTex the ...
1
vote
0answers
28 views

Using mcode within a beamer frame [duplicate]

I have a presentation that I would like to include some matlab code in. For that purpose I have included the mcode package, that basically configures the listings package. My problem is that the ...
1
vote
0answers
292 views

error:out of memory error in matlab [closed]

I am trying to write a matlab code for image morphing . I have to prewarp the images first , i have used imwarp function with the tform as follows , the code is , function []= ...