Hi all,
I'm very new to using more powerful statistical software and am slowly learning the ropes. I'm good at implementing feedback, but not so great at my own research.
I work with batteries. We gather a ton of data, and we use different tests depending on what we want to find out. The data generated is cyclical in nature, as we charge the cell, rest it, discharge it, and rest it again. These are called steps.
In one test (I call them runs), we may have several cycles at one regime, then several cycles in another. Therefore, it is important for me to be able to track responses (currents, voltages, capacities, energies, etc.) as factors of cycles, steps as well as runs.
Onto my query: I need a column formula which will start at 11, and then increment up by a value of 1 every 4 rows. This column will track the total number of cycles across multiple runs. The reason why it needs to increment by 4 is that that is how many steps there are in each cycle.
To further clarify, let me give an example.
Column 1 is labelled Run. It tracks the number of a particular test in series.
Column 2 is labelled Total Cycle Number. This is the column which I need to code properly.
Column 3 is labelled Actual Cycle Number. It describes the cycle number of a particular test. These values are cyclical, and go back to 1 at the start of each new Run. Their upper bound is not consistent. The values also repeat depending on how many steps are in each cycle. An example of the values would be 1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,1,1,1,1,2,2,2,2, etc.
Column 5 is labelled RawStepID. It resets back to 1 at the start of each cycle. An example would be 1,2,3,4,1,2,3,4,1,2,3,4, etc.
Column 6+ is any data that is obtained.
My approach so far to Column 2 has been to try and prepare an IF statement with a local variable. I want it to increment this variable by a value of 1 everytime RawStepID == 1. I need it to start at 11, then become 12 when RawStepID=1, become 13 next time RawStepID=1, etc. Then I need the formula to display the current value of the variable.
I.e., if using the data I typed for Column 3, I need the values of this column to become
11,11,11,11,12,12,12,12,13,13,13,13,14,14,14,14,15,15,15,15,16,16,16,16,17,17,17,17,18,18,18,18, etc.
I hope this is clear. In the meantime I will try and work out how to include a table in a forum post as I've seen other members do, or failing that create a dummy table to attach to here.
Thanks,
ScaredAntelope.