Dear All,
I have the following sample of data
I would like to generate to summarize the variable efi for each id. Hence, I type:
What I would like next is to export each summary statistics in a single table Something like:
However I cannot figure out how I can get it. Anu hint?
Thanks in advance
Dario
I have the following sample of data
Code:
* Example generated by -dataex-. For more info, type help dataex clear input double efi float id double fyear 8.48 1 2000 8.32 1 2002 8.34 1 2003 8.37 1 2004 8.24 1 2005 8.25 1 2006 8.29 1 2007 8.11 1 2008 7.77 1 2009 7.89 1 2010 7.8 1 2011 7.87 1 2012 7.78 1 2013 7.88 1 2014 7.98 1 2015 8.03 1 2016 8.05 1 2017 8.01 1 2018 7.99 1 2019 8.53 2 2000 8.38 2 2003 8.4 2 2004 8.33 2 2005 8.31 2 2006 8.35 2 2007 8.12 2 2015 8.15 2 2016 8.2 2 2017 8.15 2 2018 8.12 2 2019 8.37 3 2002 8.38 3 2003 8.4 3 2004 8.33 3 2005 8.31 3 2006 8.35 3 2007 8.21 3 2008 8 3 2010 7.97 3 2011 8.05 3 2012 7.94 3 2013 8.04 3 2014 8.12 3 2015 8.2 3 2017 8.15 3 2018 8.12 3 2019 8.57 5 2000 8.4 5 2001 8.4 5 2002 8.42 5 2003 8.45 5 2004 8.35 5 2005 8.35 5 2006 8.35 5 2007 8.17 5 2008 7.86 5 2009 7.95 5 2010 7.89 5 2011 7.98 5 2012 7.91 5 2013 8.01 5 2014 8.11 5 2015 8.15 5 2016 8.18 5 2017 8.13 5 2018 8.08 5 2019 8.24 7 2005 8.25 7 2006 8.29 7 2007 8.11 7 2008 7.87 7 2012 7.78 7 2013 7.88 7 2014 7.98 7 2015 8.03 7 2016 8.05 7 2017 8.01 7 2018 7.99 7 2019 8.51 10 2000 8.37 10 2001 8.36 10 2002 8.36 10 2003 8.37 10 2004 8.26 10 2005 8.28 10 2006 8.33 10 2007 8.15 10 2008 7.88 10 2009 7.95 10 2010 7.86 10 2011 7.92 10 2012 7.77 10 2013 7.88 10 2014 7.97 10 2015 8.01 10 2016 8.09 10 2017 8.05 10 2018 8.02 10 2019 end
Code:
bysort id: sum efi
id | obs. | mean | s.d. | min | max |
1 | 19 | 8.07 | 0.22 | 7.77 | 8.48 |
2 | 11 | 8.28 | 0.14 | 8.12 | 8.53 |
However I cannot figure out how I can get it. Anu hint?
Thanks in advance
Dario
Comment