[Kst] Re: Addition of sample on a specific range
Brisset, Nicolas
Nicolas.Brisset at eurocopter.com
Wed Mar 9 08:41:14 CET 2011
Ben, thanks for the reply :-)
You're right, this is the plugin to use, if you want only one scalar at the end (cost over the whole data set). However, I fear that what Mathieu wanted is a "sliding window", or "moving sum", which the plugin currently does not support. It should be easy (and it would be interesting) to add an option to compute either the cumulative sum over the whole data, or an output vector showing the cumulative sum over a given number of samples. The only "difficult" point in that case would be the values to use at the beginning, i.e. for the first samples until we have the desired window width.
And some other ideas:
- use the "Sum" automatic scalar, and generate another scalar from it if you need a scale factor (Create->Scalar->Generate and type your equation in the "Value" field of the "Generate" group). This has the advantage that you can then display the value in a text label directly.
- use the Data range tool to select the right number of samples, and scroll through the data "page-wise". If the update mechanism is working as it should, you should see the label update automatically. Unfortunately, right now it seems that scalars from other scalars don't get updated. Barth, would this be easy to fix?
Mathieu: if it's not clear or if we haven't understood the case, just refine your question.
Nicolas
________________________________
Von: Ben Lewis [mailto:asuomynona at gmail.com]
Gesendet: Mittwoch, 9. März 2011 07:41
An: kst at kde.org
Betreff: [Kst] Re: Addition of sample on a specific range
Hi Mathieu,
If you are sampling at regular intervals you could try using the "Cumulative Sum" plugin found under Create > Filter Plugin > Cumulative Sum.
This will give you a running total of energy used.
You can then use an equation found under Create > Equation to calcuate the total cost.
You will need to be consistent with your units, so if power is measured in Watts and the cumulative sum variable, dx, is entered in seconds, then the unit cost of electricity will need to be $/W-s.
I hope this helps.
Cheers, Ben
On 8/03/2011 2:49 PM, mathieu660r at gmail.com wrote:
Hi,
I'm new here and I find KST a really great tool for fast and efficient plotting. I'm currently using some hardware to measure the real power of some lights. I can plot the power easily and I can get the power value on the y axis and the time on the x axis. My question is a little bit complex so I will try to explain the best as I can if you have questions please ask. So I want to add all the value of a time sample ( example : all the value during 60 minutes and do it for each 60 minutes) and multiply the total value by another value to get an approximation of the cost of electricity.
Thanks,
Mathieu R.
_______________________________________________
Kst mailing list
Kst at kde.org
https://mail.kde.org/mailman/listinfo/kst
Eurocopter Deutschland GmbH
Sitz der Gesellschaft/Registered Office: Donauwoerth
Registergericht/Registration Court: Amtsgericht Augsburg HRB 16508
Vorsitzender des Aufsichtsrates/Chairman of the Supervisory Board: Dr. Lutz Bertling
Geschaeftsfuehrung/Board of Management:
Dr. Wolfgang Schoder, Vorsitzender/CEO; Friedrich-Wilhelm Hormel; Ralf Barnscheidt
CONFIDENTIALITY NOTICE
This communication and the information it contains is intended for the addressee(s) named above and for no other persons or organizations. It is confidential and may be legally privileged and protected by law. The unauthorized use, copying or disclosure of this communication or any part of it is prohibited and may be unlawful.
If you have received this communication in error, kindly notify us by return e-mail and discard and/or delete the communication. Thank you very much.
It is possible for e-mails to be intercepted or affected by viruses. Whilst we maintain virus checks on our e-mails, we accept no liability for viruses or other material which might be introduced with this message.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.kde.org/pipermail/kst/attachments/20110309/96df5187/attachment-0001.htm
More information about the Kst
mailing list