Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at statalist.org.
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: st: Using scalars to create a histogram
From
Nick Cox <[email protected]>
To
"[email protected]" <[email protected]>
Subject
Re: st: Using scalars to create a histogram
Date
Sun, 22 Sep 2013 17:00:31 +0100
Put them in a variable. E.g.
gen y = .
qui forval i = 1/500 {
replace y = scalar(s`i')
}
assuming that you have 500 or more observations.
Nick
[email protected]
On 22 September 2013 13:07, George Murray <[email protected]> wrote:
> Dear Statalist,
>
> Suppose I have scalars s1, s2, …, s500 (these are not the only scalars
> saved in the memory), and I wish to draw a histogram of these scalars.
> Can anyone suggest a method of doing this?
>
> Also, suppose I have scalar q1. Any suggestions on how to find how
> many s1,…,s500 are larger than q1?
>
> Thanks,
>
> George.
>
> *
> * For searches and help try:
> * http://www.stata.com/help.cgi?search
> * http://www.stata.com/support/faqs/resources/statalist-faq/
> * http://www.ats.ucla.edu/stat/stata/
*
* For searches and help try:
* http://www.stata.com/help.cgi?search
* http://www.stata.com/support/faqs/resources/statalist-faq/
* http://www.ats.ucla.edu/stat/stata/