cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Try the Materials Informatics Toolkit, which is designed to easily handle SMILES data. This and other helpful add-ins are available in the JMP® Marketplace
Choose Language Hide Translation Bar
B1234
Level III

Moving Average

I have a data set of >300 rows. I want to create a column that has the moving average of the previous 20 rows of the Results column. 

 

I want my new moving average column will look like this

rows 1 to 20 will be blank, 

row 21 will have the average result of rows 1-20 of the Results column, 

row 22 will have average results of rows 2-21 of the Results column, 

row 23 will have average results of rows 2-22 of the Results column

1 ACCEPTED SOLUTION

Accepted Solutions
David_Burnham
Super User (Alumni)

Re: Moving Average

You should double-check that this gives the correct numbers but I think this is the sequence:

 

1. Right click on the column and select New Formula Column

2. Select Row> Moving Average

3. For Weight, specify 'Equal'

4. For Items Before, specify 'Fixed', and enter a value of 20

5. Select 'report missing values for partial window'

6. Click OK

-Dave

View solution in original post

1 REPLY 1
David_Burnham
Super User (Alumni)

Re: Moving Average

You should double-check that this gives the correct numbers but I think this is the sequence:

 

1. Right click on the column and select New Formula Column

2. Select Row> Moving Average

3. For Weight, specify 'Equal'

4. For Items Before, specify 'Fixed', and enter a value of 20

5. Select 'report missing values for partial window'

6. Click OK

-Dave