# przykład 2.9 attach(cpus) xp<-seq(64.0,64000,length=100) yp<-seq(0.0,256,length=100) cpusT<-expand.grid(mmax=xp,cach=yp) cpus.tr<-tree(log10(perf)~mmax+cach,cpus) plot(cpus.tr) text(cpus.tr) partition.tree(cpus.tr) cpusT$perf<-predict(cpus.tr, newdata=cpusT,type="vector") pp<-matrix(cpusT$perf,50,50) persp(xp,yp,pp,theta = -45, phi = 30, expand = 0.7, d=0.5, ltheta = 30, shade = 0.3,ticktype="detailed",nticks=6,xlab = "mmax",ylab = "cach",zlab = "log10(perf)")->rr points(trans3d(cpus$mmax, cpus$cach, 10, pm = rr), col = 2, pch =16)