Answered
query horizonal range of 3-D views
Read about slice.

5 years ago | 0

Answered
convert for loop's answers into a vector
mean(aR2) is a scalar value, why you want to store it into a vector? Are you looking for saving values in a loop into a array?...

5 years ago | 0

| accepted

Answered
Intersections between line and rectangle
Use this file exchange function: https://in.mathworks.com/matlabcentral/fileexchange/22441-curve-intersections

5 years ago | 0

| accepted

Answered
How to find (0,0) in a meshgrid?
x = -10:1:10 ; y = -5:1:5 ; [X,Y] = meshgrid(x,y) ; idx = knnsearch([X(:) Y(:)],[0 0]) ; plot(X,Y,'.r') hold on plot(...

5 years ago | 0

| accepted

Answered
% 34.- Plot the surface % f(x, y) = x y e^(-x^2-y^2) % over the domain [-2; 2] × [-2; 2]. % Find the values and the locations of the minima and maxima of this function.
Read about pcolor, surf for plotting. To get minimum and maximum read about min and max respectively.

5 years ago | 0

Answered
From arrays of two columns into multiple circles
C = rand(10,2) ; plot(C(:,1),C(:,2),'o','Markersize',10) If you want circle with given radius R. C = rand(10,2) ; R = 4 ; ...

5 years ago | 0

| accepted

Answered
how to make a spatial map with two dimensional matrix
Let X, Y, Z be your data. Where X is m*n, Y is m*n and Z is m*n*p matrix. for i = 1:p pcolor(X,Y,Z(:,:,i)) drawnow ...

5 years ago | 0

Answered
Why Using '%f' as formatspec for a text file containing floating numbers gives no output
data = importdata('data.txt') ; data = data.data ; t = data(:,7) ; x = data(:,17) ; y = data(:,16) ; lat = [32.48...

5 years ago | 0

Answered
What does C(:,:,i)=[Q11 Q12 Q14;Q12 Q22 Q24;Q14 Q24 Q44]; signify?
C(:,:,i)=[Q11 Q12 Q14;Q12 Q22 Q24;Q14 Q24 Q44]; In the above C, is 3D matrix initialized as 3*3*p matrix. Each matrix of C, sh...

5 years ago | 0

Answered
Plot a circle with the radius r = 2, % knowing that the parametric equation % of a circle is % [x(t); y(t)] = % [r cos(t); % r sin(t)] for t = [0; 2pi]
If I want to plot sine, I will follow as below: t = linspace(0,2*pi,100) ; x = sin(t) ; plot(t,x) ; Use the above as exampl...

5 years ago | 2

Answered
Except for the first iteration others show NaN
Try reducing the initial learning rate. options = trainingOptions('adam') ; options.InitialLearnRate options.InitialLearnRat...

5 years ago | 0

| accepted

Answered
Plot 3D shape with grid cell
You have variety of functions to achieve it. It depends on what data you have. I assume you have a 3D volume data i.e. matrices ...

5 years ago | 0

Answered
How to remove contour line in filled contour plot?
Try: pcolor(x,y,z) ; colorbar ; shading interp ;

5 years ago | 0

Answered
How to set one specific point on a 3-D surface ?
[X,Y,Z] = peaks(100) ; [val,idx] = max(Z(:)) ; surf(X,Y,Z) ; shading interp hold on plot3(X(idx),Y(idx),Z(idx),'+r')

5 years ago | 0

Answered
Range of numerical values
Read about single and double floating point numbers. Range of single: 2^(-126) to 2^(127) Range of double: 2^(-1022) to 2^(10...

5 years ago | 0

Answered
How can i draw this kind of graph from data file?
Read about contour, plot and xticklabel.

5 years ago | 0

Answered
Problem in Generating Random Values
clc, clear all a = input('a = '); b = input('b = '); c = input('c = '); for i = 1:100 u = rand; x(i) = b(u+(a/b)...

5 years ago | 0

| accepted

Answered
If statement in a for loop
[m,n] = size(A) ; iwant = cell(m,n); for i = 1:m for j = 1:n T = A{i,j} ; T(T>1) = 0.25 ; ...

5 years ago | 1

Answered
get data from function
From the function r should be a m*2 matrix. It should have two columns. And x should be a 1*4 array.

5 years ago | 1

| accepted

Answered
How can I write a variable that goes from 0 to 2pi and the array has 200 values
theta = linspace(0,2*pi,200) ;

5 years ago | 0

| accepted

Answered
Hoe to get distance data in a specific zone?
If you have the positions, find the distance between the two successive points using distance formula. You can sum all these d...

5 years ago | 0

Answered
How to get correlation coefficient between data with Monte Carlo?
Read about regression, corr2, corrcoef.

5 years ago | 0

Answered
How to find unique matrix or matrix combination from given permutations?
Read about ismember and unique.

5 years ago | 0

Answered
How do I concatenate two matrices into alternating rows?
A = rand(2,4) ; B = rand(2,4) ; C(1:2:4,:) = A ; C(2:2:4,:) = B ;

5 years ago | 1

| accepted

Answered
2d ternary contour map
Read about delaunayTriangulation. This is your function. Demo: x = rand(10,1) ; y = rand(10,1) ; z = rand(10,1) ; w = ran...

5 years ago | 0

| accepted

Answered
how to draw a directional field for this equation?
You may have a look on this file exchange function which help you to plot the directional plot. https://in.mathworks.com/matla...

5 years ago | 0

| accepted

Answered
Index exceed array bound error showing....
You are trying to extract more number of elements than present in the array. You need to have a look on the maxiimum index of yo...

5 years ago | 0

Answered
Centroids distance in pixel
Read about the function knnsearch, this will give you the specified number of nearest points from a set of points for a given po...

5 years ago | 0

Answered
convert double NaN to string NaN
A = NaN(2,5) ; C = arrayfun(@num2str,A,'UniformOutput',false)

5 years ago | 0

| accepted

Load more