MATLAB: How do I expand the region of a plot saved through hgexport?
-
So I used the command hgexport(gcf, 'figure1.jpg', hgexport('factorystyle'), 'Format', 'jpeg'); on my graph, and I get this weird graph below. Is there a way to auto-save images I generate with Matlab - with all the axes expanded out to full screen, so that all these plots won't be squished together? (I've asked SE at http://stackoverflow.com/questions/18544568/how-to-expand-region-of-a-plot-saved-through-hgexport but they can't find a solution so far)
-
Answer:
You can change the dimensions of your figure before running hgexport using the PaperPosition setting, e.g. set(gcf, 'PaperPositionMode', 'manual'); set(gcf, 'PaperUnits', 'inches'); set(gcf, 'PaperPosition', [2 1 4 2]); (more details here: http://www.mathworks.com/help/matlab/creating_plots/changing-a-figures-settings.html#f3-137140). From "auto-save" it sounds like you want to use a bitmap format, but another suggestion is that you may have fewer problems with dimensions if you tried exporting to a vector graphics format such as .eps.
Keith Callenberg at Quora Visit the source
Related Q & A:
- How do I display all categories on a page with a corresponding image?Best solution by Magento
- How do I change the cursor from a blinking black block to a blinking line?Best solution by Server Fault
- How can I lower the resolution on a video I recorded?Best solution by Yahoo! Answers
- How do I embed .srt subtitles on a video if I have a Mac?Best solution by answers.yahoo.com
- How can I play my PS3 using a laptop as a monitor?Best solution by Yahoo! Answers
Just Added Q & A:
- How many active mobile subscribers are there in China?Best solution by Quora
- How to find the right vacation?Best solution by bookit.com
- How To Make Your Own Primer?Best solution by thekrazycouponlady.com
- How do you get the domain & range?Best solution by ChaCha
- How do you open pop up blockers?Best solution by Yahoo! Answers
For every problem there is a solution! Proved by Solucija.
-
Got an issue and looking for advice?
-
Ask Solucija to search every corner of the Web for help.
-
Get workable solutions and helpful tips in a moment.
Just ask Solucija about an issue you face and immediately get a list of ready solutions, answers and tips from other Internet users. We always provide the most suitable and complete answer to your question at the top, along with a few good alternatives below.