Statalist


[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

Re: st: multiple graphs


From   Daniel Stegmueller <[email protected]>
To   [email protected]
Subject   Re: st: multiple graphs
Date   Sat, 14 Jun 2008 22:21:57 +0200

You can get the behavior you want (several graphs in one window using tabs) by setting the autotabgraphs option.
See - help autotabgraphs -.

I can't give you more details, since its only available on windows...

Daniel





moleps islon <[email protected]>:
You could write a little program to generate temporary names for your
graphs easily enough. E.g.

prog nn
syntax anything [, *]
tempfile n
loc name="G"+reverse(substr(reverse("`n'"),5,7))
`anything', name(`name') `options'
end

sysuse auto, clear
nn sc mpg wei
nn sc gear wei


On Sat, Jun 14, 2008 at 12:00 PM, moleps islon <[email protected]> wrote:

it works. However I find the multiple graph thing rather cumbersome.
The essence is that you have to give each graph a separate name.

However I think it would be more userfriendly to have a graph
routine/window automatically giving new tabs labeled graph1...2..3..4
etc.etc in case one doesnt invoke the name option.
Regards

On Sat, Jun 14, 2008 at 5:54 PM, Martin Weiss
<[email protected]> wrote:
This creates three tabs with three distinct graphs for me:

*****
sysuse auto, clear

loc vars "price mpg weight"

foreach var of loc vars{
      hist `var', name(mygr`var', replace)
}
********

What happens when you run this code?

Zitat von moleps islon <[email protected]>:

But shouldn't there be an option somewhere in stata to let me have
mutiple graphs under induvidual tabs in the graph window? Or several
graph windows?
regards,
Moleps

On Sat, Jun 14, 2008 at 5:32 PM, Martin Weiss
<[email protected]> wrote:


in the options to the graph, say -save(mygraph1, replace)- and possibly
-nodraw- if all you want is to -gr combine- afterwards...

Zitat von moleps islon <[email protected]>:


How do I instruct stata to retain the different graphs while running a
do file? From the looks of it stata closes the graph window before
starting a new graph command. I've turned on the mutiple graphs tab in
preferences...
*
*   For searches and help try:
*   http://www.stata.com/support/faqs/res/findit.html
*   http://www.stata.com/support/statalist/faq





*
*   For searches and help try:
*   http://www.stata.com/support/faqs/res/findit.html
*   http://www.stata.com/support/statalist/faq
*   http://www.ats.ucla.edu/stat/stata/



© Copyright 1996–2024 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index