如何计算 Spotfire 曲线下的面积?

How to Calculate Area Under the Curve in Spotfire?

有人可以帮助我使用 R 或 S+ 计算 Spotfire w/o 中曲线下的面积吗?

我想对每个Well进行[K](1=最大值)的数据排序,然后计算[P](按K降序排列)和[K]的累加和,然后计算和绘制(作为曲线)[P] 和 [K] 的累积总和百分比,计算每个曲线下的面积,对于每个孔(表达式是什么)。

我想计算 Spotfire 中的每一列,但我的主要问题是排名 [K],所以没有关系(我试图先按 [K] 排名,然后按 [Depth] 排名),总结[P]和[K]的值按每个Well的[K]排序,然后计算每条曲线下的黎曼和(面积)。

首先您需要添加一个新列 ([period]) 来计算唯一时间,否则 Spotfire 会混淆数据集中的不同时间:
[well] & Log10([time] + 1)

然后打叉table,拖[well]到纵轴,在单元格值中输入这个表达式: Sum(([pressure] + Avg([pressure]) over (Next([period]))) / 2 * (Avg([time]) over (Next([period])) - [time]))

或者您可以添加一个新列 ([AUDPC_helper]) 也请参阅分步计算:
([pressure] + Avg([pressure]) over (Intersect(NextPeriod([period]),[well]))) / 2 * (Avg([time]) over (Intersect(NextPeriod([period]),[well])) - [time])
只需要在例如一个十字架 table