Kristi Glover
2013-Apr-13 10:34 UTC
[R] how can I convert a result (text) in table format in R?
Hi R user, Could you please give me some hints on how I can convert text in table format in R? I was doing model assessment using dismo package for example: bg <- randomPoints(current, 500) pvtest <- data.frame(extract(current, occtest)) avtest <- data.frame(extract(current, bg)) e2 = evaluate(model, p=pvtest, a=avtest)> e2class : ModelEvaluation n presences : 10 n absences : 1000 AUC : 0.9952 cor : 0.6453986 max TPR+TNR at : 0.4496625 I wanted to put the e2 into table. How can I change the text (e2 results) in table format? Thanks Kristi [[alternative HTML version deleted]]
David Winsemius
2013-Apr-13 19:36 UTC
[R] how can I convert a result (text) in table format in R?
On Apr 13, 2013, at 3:34 AM, Kristi Glover wrote:> Hi R user, > Could you please give me some hints on how I can convert text in table format in R? > I was doing model assessment using dismo package > for example: > bg <- randomPoints(current, 500)I doubt very much that 'randomPoints' is a base function. You are asked to include the names of contributed packages. Failing to do so implies that you expect us to go search for the package. I used to do so but have abandoned that action since it implicitly encourages inconsiderate behavior.> pvtest <- data.frame(extract(current, occtest)) > avtest <- data.frame(extract(current, bg)) > e2 = evaluate(model, p=pvtest, a=avtest) >> e2 > class : ModelEvaluation > n presences : 10 > n absences : 1000 > AUC : 0.9952 > cor : 0.6453986 > max TPR+TNR at : 0.4496625 > > I wanted to put the e2 into table. How can I change the text (e2 results) in table format?If we knew what structure the 'evaluate' function in the unnamed package was returning, we might be able to help. There is probably either an S3-print method or an S4-show method that is displaying that text but such results are not always a good guide to what is returned as the object from a function.> Thanks > Kristi > > [[alternative HTML version deleted]]David Winsemius Alameda, CA, USA