Hello, How i can publish matlab output and code ".m file" into pdf format.
Thanks

1 Kommentar

I have a MATLAB code which generates a .txt file. Now I want to publish the code and the output text in a pdf format. Is it possible?
Currently I am able to publish only the code in the pdf format, but not the output text with it.

Melden Sie sich an, um zu kommentieren.

 Akzeptierte Antwort

madhan ravi
madhan ravi am 8 Sep. 2018
Bearbeitet: madhan ravi am 8 Sep. 2018

8 Stimmen

Try this :
publish('myfile.m','pdf')
Remark: The default file format is .html
Read the link below for better understanding:

27 Kommentare

madhan ravi
madhan ravi am 8 Sep. 2018
@Muhammad did it work?
Muhammad Ramzan
Muhammad Ramzan am 8 Sep. 2018
Bearbeitet: Walter Roberson am 9 Sep. 2018
hello thanks for the reply. and my apology for late reply. this command is not working. https://www.youtube.com/watch?v=NN65DNIDjR0&t=320s
I want to publish code and output. like in this video. but i am not able to do this. I am only able to publish the code not the graphs.
Thanks
madhan ravi
madhan ravi am 8 Sep. 2018
Bearbeitet: madhan ravi am 8 Sep. 2018
It's working for me(even the graph), ok lets try this can you see an option as publish near editor.
madhan ravi
madhan ravi am 8 Sep. 2018
let me know when you come to this step
publish button, but it is only publishing the code itself. i want to have graphs published with the code.
madhan ravi
madhan ravi am 8 Sep. 2018
Bearbeitet: madhan ravi am 8 Sep. 2018
click edit publishing button under publish button
the example given by you is working for me. but not in case of my file which i have to submit. :(
what is your email id
madhan ravi
madhan ravi am 8 Sep. 2018
Bearbeitet: madhan ravi am 8 Sep. 2018
Can you upload your file so that we can try and I'll convert it ?
i can email not upload here.
madhan ravi
madhan ravi am 8 Sep. 2018
sure
hello , have you got email.
madhan ravi
madhan ravi am 8 Sep. 2018
Bearbeitet: madhan ravi am 8 Sep. 2018
check your mail @Muhammed ,if it is what you were looking for please accept my answer
madhan ravi
madhan ravi am 8 Sep. 2018
did you check it?
yes, but it not working for me here.
Muhammad Ramzan
Muhammad Ramzan am 8 Sep. 2018
Bearbeitet: Muhammad Ramzan am 8 Sep. 2018
Please let me know. I was using the publish button. it was not working on my code. , only publishing code, not the graphs.
madhan ravi
madhan ravi am 8 Sep. 2018
did you check it( above comment) now?
yes , but not working for me. what have you done.
I am doing the same steps. and can you please delete the file from here Please
madhan ravi
madhan ravi am 8 Sep. 2018
madhan ravi
madhan ravi am 8 Sep. 2018
madhan ravi
madhan ravi am 8 Sep. 2018
yes this is working for me
thanks
I have voted.
Hello @ madhan ravi. Thanks for the help. can you please help
syms x
f =x.^2
fplot(f)
t = 1: 256
how i can ply. publish graph and not the output of
t = 1: 256
thanks
t=1:256;
just suppress the output by putting semicolon(;)

Melden Sie sich an, um zu kommentieren.

Weitere Antworten (4)

Alan Hernandez Ramirez
Alan Hernandez Ramirez am 4 Feb. 2020

5 Stimmen

bruh
dont use publish('myfile.m','pdf') if youre using the matlab online version
it crashed my computer opening so many figue pages hahahaha

3 Kommentare

How do you publish then if you use the online version of matlab?
Same
KARI WEISS
KARI WEISS am 15 Sep. 2020
same question

Melden Sie sich an, um zu kommentieren.

Walter Roberson
Walter Roberson am 8 Sep. 2018

2 Stimmen

"You specify the output format and location on the Publish settings pane. "
sujit
sujit am 26 Mär. 2024

0 Stimmen

computing average marks of a student?

Kategorien

Mehr zu Data Import and Export finden Sie in Hilfe-Center und File Exchange

Tags

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by