Dear Whom it may concern,
I need help to figure the "macro" function in R: I need to plot the
different data sets by a plotxyf function, I want the title to be different
for different data set.
# get the data set
final.xyf<- xyf(data=as.matrix(my.final),
Y=classvec2classmat(final$outcome), xweight = 0.5, grid=somgrid(5, 4,
"hexagonal"))
#plot function
plotxyf<-function (data) {
plot(data, type="mapping", labels=final$target, col=final$outcome+1,,
main="Supervised: Mapping plot for data")
}
#use the plotxyf function.
plotxyf(final.xyf)
But the result is not I expected, the title is "Supervised: Mapping plot for
data", not "Supervised: Mapping plot for final.xyf"
CAn anyone help me with this?
Thanks so much!
--
Sincerely,
Changbin
--
[[alternative HTML version deleted]]
______________________________________________
[email protected] 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.