Hi:

You're fitting y as a function of x; as in any regression model, the x's are
assumed to be conditionally fixed. If you want to model x as a function of
y, that's a calibration problem.

There are several issues at play:

1. In the model, you have assumed x is fixed, but afterward, you want to
treat it as random.
2. You're implicitly assuming that the relationship between Y and X is
invertible. If this were a math problem, you would be right:   y = a exp(b *
x)   =>  x = (1/b) log(y/a). Unfortunately, this is a statistical problem,
and several problems arise, among them:
       - the X and Y scales are very different, which suggests
         rather strongly that the distribution associated with
         random variation in Y is not the same as the distribution
         associated with random variation in X.
      -  the distribution of random errors in Y is quite likely not
         going to have the same relationship to the distribution
         of random errors in X as the functional relationship
         between x and y above. More succinctly, the problem is a
         lack of invariance, so you can't simply invert the problem
         at the end.
3. Predictions are only as valid/reliable as the underlying model and its
attendant assumptions. Your request to predict x as a function of y is
essentially acknowledging that the prediction is useless before it is ever
made, by point (1).

Chemometrics deals with calibration problems regularly - I presume that many
calibration functions are nonlinear, so you may find something useful by
hunting in that area. In econometrics, a related (but not equivalent)
problem is the so-called 'errors in variables', in which both y and x are
assumed to be random. Of course, you could model the problem from a Bayesian
perspective and hope that MCMC comes to the rescue :)

The bottom line is that a statistical relationship between y and x does not
translate to a corresponding relationship between x and y (through
mathematical inversion). Basically, they are treated as separate problems,
which makes sense because the conditional distribution of Y|X = x is not the
same as that of X|Y = y.

HTH,
Dennis

2010/9/8 Елена Белых <daryd@rambler.ru>

>
> Dear colleagues!
> Is it possible to make predictions in R?
> there is an exponential relationship detween y and x
> x<-c(0.001,0.003,0.01,0.16,0.3,0.7,0.9)
> y<-c(38.8,41.5,44.2,27,26.9,6.9,3)
> f<-function(x,a,b){a*exp(b*x)}
> fm<-nls(y~f(x,a,b), start=c(a=1,b=1))
>
> How one can predict x when y=10 and is it possible to calculate standard
> error of x?
> The task is equal to function ED in drc package, but it use logistic
> regression only.
>
> Best regards,
> Elena.
>
> --
> daryd@rambler.ru.
>
> ______________________________________________
> R-help@r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide
> http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.
>

	[[alternative HTML version deleted]]

