how to plot node in particular range but x and y lim is 1000x1000

1 vue (au cours des 30 derniers jours)
singh
singh le 10 Juil 2015
Modifié(e) : singh le 10 Juil 2015
bs=4;
area=1000;
X_coord=rand(1,bs)*area
Y_coord=rand(1,bs)*area
if ((X_coord<=100)&(X_coord>=880))
X_coord=rand(1)*area
end
if ((Y_coord<=100)&(Y_coord>=880))
Y_coord=rand(1)*area
end
for i2=1:bs
plot(X_coord(i2),Y_coord(i2),':o','LineWidth',3,'MarkerEdgeColor','k','MarkerFaceColor',...[0.5,0.5,0.5],'MarkerSize',3)
text(X_coord(i2),Y_coord(i2),'BS')
hold on
end
In above coding i need some solution if X_coord and Y_coord value is less than 100 and gteater than 880 shown in 3 and 4 line of above code, then it will again calculate particular X_coord and Y_coord value for ploting

Réponses (0)

Catégories

En savoir plus sur Data Exploration dans Help Center et File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by