Hello all,
I currently have the following data set, and a table will look like this:
| Test | Iteration | Results | 
| Test1 | 1 | 400 | 
| Test1 | 2 | 500 | 
| Test1 | 3 | 600 | 
| Test2 | 0 | 1000 | 
| Test2 | 1 | 500 | 
| Test2 | 2 | 1000 | 
| Test2 | 3 | 2000 | 
We run a test several times and save the results for each time.
What I need to do is to calculate iteration 0 for the tests that don't have it (test1), which will be a median of all other iterations available. What I want to do is add a new for, with the new value:
| Test | Iteration | Results | 
| Test1 | 0 | 500 | 
| Test1 | 1 | 400 | 
| Test1 | 2 | 500 | 
| Test1 | 3 | 600 | 
| Test2 | 0 | 1000 | 
| Test2 | 1 | 500 | 
| Test2 | 2 | 1000 | 
| Test2 | 3 | 2000 | 
It needs to add only the iteration 0 for those tests that doesnt have it, and ignore the other cases.
I've tried using appendpipe + eventstats, but It only rewrites the Iteration and Value fields:
|appendpipe [ |eventstats median(Results) as Results, first(Test) as Test, | eval iteration=0 ]
I would like to get some ideas on how to do this.
Any help will be appreciated, thank you in advance.
