Community Profile

# Mirthand

Last seen: 約2年 前 2021 年からアクティブ

バッジを表示

#### Content Feed

for loop to subtract every element from the first element for a given trial
I have two columns with TrialNumber and Minutes in the table tt (please see attached). I'm trying to get the Minutes to start ...

### 1

Find time elapsed in a table (for loop)?
I have a table with two columns, TrialNumber and Minutes (attached). The trials represented are 15 30 45 60 75 90 U...

### 1

How to restart the time for each trial? (help with a for loop in a table)
I have a table with two columns, TrialNumber and Minutes that I've attached. I want each trial to start from 0. I was able to r...

### 1

How to change a value in one column dependent on another table column?
I have a table (attached) with two columns. I'd like to match Var1 and Var2. For example all the Var2 should have the same V...

### 1

Changing a a value in table column dependent on another column.
In the table I would like column e to replace the the first two 78 with 1. The 1 value should match with column d and the 2 valu...

### 1

How to find the first element in ascending numbers that repeat?
I want to find the index of the first instance of a number only when the next number is ascending. A = [1 2 3 4 0 1 0 1 0 1 ...

### 2

How to find the first number, ignore subsequent until a greater number repeats.
A = [ 0 3 0 3 0 3 0 3 0 4 0 4 0 4 0 4 0 5 0 5 0 5 0 5 0 5 0 3 0 3 0 3] b = find(A==3) 2 4 6 8 28 30 ...

### 2

How to find a number but if it repeats immediately after, take the first value.
I want to be able to find the index of the first 5 in but ignore the other 5's if they are immediately right after. In the exa...

### 2

Counting in one column that is conditional on another column
For each cell (or "trial") in the variable trials (attached): I'd like to count the number of 1's in column 4 that is dependent...

### 2

How to change a portion of cell array?
I have a large data set where I've put trials into a cell array. So each cell contains 1 trial and within that cell trial{1,1} t...

### 1

How to keep TRUE if followed by FALSE but if TRUE is followed by TRUE, change the second TRUE to false?
I have an array of logic 1 and 0's. If 1 is immediately followed by another 1, I want to change this second 1 to a 0. trial_i...