- Data Structure
- Networking
- RDBMS
- Operating System
- Java
- MS Excel
- iOS
- HTML
- CSS
- Android
- Python
- C Programming
- C++
- C#
- MongoDB
- MySQL
- Javascript
- PHP
- Physics
- Chemistry
- Biology
- Mathematics
- English
- Economics
- Psychology
- Social Studies
- Fashion Studies
- Legal Studies
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
How to create two 3d plots at a time in R?
The rgl package is specifically designed to create real-time interactive 3D plots and we can create two 3d plots using plot3d function of this package. Also, these plots can be viewed in the R console at a single point of time with the help of open3d() function.
Example
Loading rgl package:
Example
> library(rgl) > x<-rpois(200,5) > y<-rpois(200,2) > z<-rpois(200,3) > plot3d(x,y,z)
Output
Example
> open3d() wgl 12 > plot3d(x,y,z,col=rainbow(5))
Output
Advertisements