Community Profile

# Jillian Sweatt

7 total contributions since 2015

View details...

Contributions in
View by

Question

How do I exclude NaN values when calculating mean of each row in a matrix?
gpd=[2014,3.320,3.364,3.532,3.659,3.691,3.695,3.633,3.481,3.403,... 3.182,2.887,2.560;2015,2.110,2.249,2.483,2.485,2.77...

2 years ago | 4 answers | 0

### 4

Question

How can the nested if statement in the last for loop be rewritten to be shorter?
clear; close all n = 4000; % (A) Use rand to generate randomly distributed points: Rand_Number = rand(n, 2); x = Ra...

3 years ago | 1 answer | 0

### 1

Question

How do you rewrite the nested if statement as a loop?
clear; close all n = 4000; % (A) Use rand to generate randomly distributed points: Rand_Number = rand(n, 2); x = Ra...

3 years ago | 1 answer | 0

### 1

Question

How do you rewrite the nested if statement as a loop?
for i=1:length(x) if x(i) >= -1 && x(i) <= -0.9 count(1) = count(1)+1; elseif x(i) >-0.9 && x(i)<-0.8...

3 years ago | 1 answer | 0

### 1

Question

How to suppress the ans in a user defined function
I have been having trouble getting my code to stop outputting the ans and just output the values. function [mn,md,mo,V,Std,...

4 years ago | 2 answers | 0

### 2

Question

How do I sort an array in descending order without using the sort function?
A = [2 1 4 3 6 5 8 7 10 9 12 11 14 13 16 15 18 17 20 19]

4 years ago | 3 answers | 0