Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation since 02/19/2024 in all areas

  1. Hey there, The key here is using the `aggregate` function, with a minValue() argument. The aggregate function handles Conditions, rather than capsules. You can also output the minValue() at the minKey(), which is the timestamp when the minimum value occurs. Then, transforming that value into a new Condition, of zero-length capsules as the start, will create capsules at the minimum point, which will ultimately be used as the starting point to connect to when your signal == 25.2 $searchCondition = $originalCondition.removeLongerThan(30d).grow(1hr) //notice the .grow(1hour) to expand your capsules in case the minimum happens earlier // Assuming $signal is your signal of interest and $originalCondition is the condition with the capsules of interest $minValueTimes = $signal.aggregate(minValue(), $searchCondition, minKey()) // Convert the times of minimum values into a new condition with zero-length capsules $newConditionAtMinValues = $minValueTimes.toCondition().starts() // Output the new condition $newConditionAtMinValues Then create a Value Search to find when your Signal = 25.2 (no screenshot for this one 🙂 ) Finally, you can use the Composite Condition tool to "join" the two capsules: And your ultimate goal was calculating the duration between those periods, so you can use the "Signal from Condition" tool to calculate it's Duration like this: Performing it all in one, giant Formula, would look like this: where $originalCondition is your derivative > .001 condition, and $signal is your base signal. $searchCondition = $originalCondition.removeLongerThan(30d).grow(1hr) // Assuming $signal is your signal of interest and $originalCondition is the condition with the capsules of interest $minValueTimes = $signal.aggregate(minValue(), $searchCondition, minKey()) // Convert the times of minimum values into a new condition with zero-length capsules $newConditionAtMinValues = $minValueTimes.toCondition().starts() // Perform your value search $valueSearch = $signal < 36.2 // Join the two conditions $JoinedCondition = $newConditionAtMinValues.join($valueSearch.beforeStart(0ns), 40hr, true) // Calculate the duration of the joined Condition $JoinedCondition.aggregate(totalDuration('hours'), $JoinedCondition, durationKey()) Hope that helps!! -Chris Orr
    1 point
  2. Question: My problem is that I can’t seem to make asset trees that have branches with different lengths using spy.assets.Tree(). This is frustrating because it means for (effectively) shorter branches I’ll have to click through several folders to get down to the folder with tags in it. Answer: Let say for Cooling Tower 2, you want the signals to be populated directly under Cooling Tower 2. If you leave the column ‘’Level 3’’ blank, you’ll get this error: Instead, you want to insert NAN into the empty ‘’Level 3’’ column like this: Hope this helps.
    1 point
This leaderboard is set to Los Angeles/GMT-07:00
×
×
  • Create New...