[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: st: Cumulative Percentiles & Accuracy Profiles

From   Eva Poen <>
Subject   Re: st: Cumulative Percentiles & Accuracy Profiles
Date   Thu, 2 Apr 2009 14:48:24 +0100


does it have to be the bin comparison? Another useful way to do such
comparisons is a -qqplot- (-help diagnostic_plots-). -qqplot- plots
the percentiles of variable 1 (e.g. your dependent variable) agains
the percentiles of variable 2 (e.g. your predicted values). If they
are exactly the same, the plot produces a straight line. It's a nice
way to see how the two distributions differ.

Hope this helps,

2009/4/2 Ronan Gallagher <>:
> Hi,
> I am doing some modelling using Stata and wish to draw a cumulative accuracy
> profile.  Essentially I have a model from which I want to compare the actual
> and predicted values of my dependent variable.
> To do this I need to create 100 bins and assign the top 1% of all predicted
> values to the first bin, the top 2% to the second bin and so forth until the
> 100th bin consists of the total number of observations.  I then want to
> repeat this exercise for the actual value of the dependent variable.  Once
> the bins are populated I need to compare how many predicted values in a
> given bin also have their actual values in the same bin.  I then need to
> plot this percentage for each bin and the resultant graphic is the
> cumulative accuracy profile for my model.
> My uncertainty centres on the cumulative nature of the bin assignment i.e.
> the first percentile of observations fall into every bin, the second
> percentile into 99 bins and the final percentile into only one bin.  The
> xtile command therefore is not as useful.
> Any help on how to compute the appropriate percentages and display the
> cumulative accuracy profile would be greatly appreciated.
> Thank-you in advance,
> Ronan

*   For searches and help try:

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