Error using patch - Non-numeric data is not supported in 'patch'. While using Plotcube

4 vues (au cours des 30 derniers jours)
Hamza Khalid
Hamza Khalid le 28 Nov 2019
Commenté : Walter Roberson le 28 Nov 2019
I'm trying to plot a cube using plotcube
plotcube([width length height],[ 0 0 0 ],1,[1 0 0]);
This is the Error I'm getting
Error using patch
Non-numeric data is not supported in 'patch'
Error in plotcube (line 49)
cellfun(@patch,XYZ{1},XYZ{2},XYZ{3},...
Error in MATLAB (line 31)
plotcube([width length height],[ 0 0 0 ],1,[1 0 0]);
Can anyone help?
Thank You

Réponses (1)

KSSV
KSSV le 28 Nov 2019
width = 1 ;
length = 1 ;
height = 1 ;
plotcube([width length height],[ 0 0 0 ],1,[1 0 0]);

Catégories

En savoir plus sur Lighting, Transparency, and Shading dans Help Center et File Exchange

Produits

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by