1

I have the following Data frame:

 cost quality safety time    status
1   13       6      3    4 Benchmark
2   10       4      5   10 Benchmark
3    8       9      3    9 Benchmark
4    7       8      9    9 Benchmark
5    4       4      4    2   current
6    2       2      7   11   current

I want to create benchmark space interms of scatter plot. So I used scatterplot3d package to draw it.

Scatterplot code:

scatterplot3d(f$cost,f$quality,f$safety,f$time,f$status)

I got the below graph, Scatterplot But I want to draw Ellipses for Benchmarks with the confidence level of .975.So I found dataEllips in car package but I do not know how To apply this function in scatterplot3d. The Graph That I want is as following:

scatter plot with ellipses

I have tried the code below, but it does not work;

scatterplot3d(dataEllipse(f$cost,f$quality,levels=0.68),f$safety,f$time,f$status)

because the function of dataEllips is coming from car package. The Error message is as following:

Error in xyz.coords(x = x, y = y, z = z, xlab = xlabel, ylab = ylabel,  : 
  'x', 'y' and 'z' lengths differ
user
  • 592
  • 6
  • 26
  • Your question is very hard to understand - especially what "benchmark space interns of scatter plot" means. Also I think it would help if you put the scatterplot3d and dataEllipse in the title. Another problem is that you should provide the code so it can be executed - the data as output of dput, the command dataEllips does not exist in car - maybe you meant dataEllips*e* - but make sure you check that. Also does not work is not a helpful information you really need to provide the error. In general functions from separate packages are not expected to work together. – bdecaf Jan 16 '16 at 10:58
  • Thanks for your constructive comments, I have updated my codes based on your comments. First of all, I want to show 4 features of my data frame on the scatter plot and make separation between the benchmark and current status, then I want to draw ellipse around benchmark points – user Jan 16 '16 at 12:58

0 Answers0