If I have a regression line and an r squared is there a simple numpy (or some other python library) command to randomly draw, say, y values for an x that are consistent with the regression? The same way you could just draw a random value from a distribution?
Thanks!
edit: I have the equation for my regression line and an r^2 value. That r^2 value should provide some information about the distribution of data points around my line, no? If I just call this y=random.gauss()*x+b haven't I lost the information in my r^2? Or would this be incorporated into the stdv, if so how? Sorry, I just haven't worked with regression much before.
y=random.gauss()*x+b
into some kind of generator expression? Can you be more specific about what's confusing you? – S.Lott Feb 24 '12 at 11:19