[chronojump] RaceAnalyzer export instantaneous fitted data = 0 when time < 0
- From: Xavier de Blas <xaviblas src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [chronojump] RaceAnalyzer export instantaneous fitted data = 0 when time < 0
- Date: Tue, 29 Jun 2021 12:29:54 +0000 (UTC)
commit ab9a5e82f8947cead0468c36219019f5b5d5aa62
Author: Xavier de Blas <xaviblas gmail com>
Date: Tue Jun 29 14:29:05 2021 +0200
RaceAnalyzer export instantaneous fitted data = 0 when time < 0
r-scripts/sprintEncoder.R | 6 ++++++
1 file changed, 6 insertions(+)
---
diff --git a/r-scripts/sprintEncoder.R b/r-scripts/sprintEncoder.R
index 2edf39be2..d969cf3b7 100644
--- a/r-scripts/sprintEncoder.R
+++ b/r-scripts/sprintEncoder.R
@@ -815,6 +815,12 @@ testEncoderCJ <- function(filename, filenameInstantaneous, testLength, splitLeng
f.fitted = srd$Mass * a.fitted + srd$Ka * (s.fitted - srd$Vw)^2
p.fitted = f.fitted * s.fitted
+ #make all fitted data be 0 when time is < 0
+ s.fitted[srd$time < 0] <- 0
+ a.fitted[srd$time < 0] <- 0
+ f.fitted[srd$time < 0] <- 0
+ p.fitted[srd$time < 0] <- 0
+
print(length(s.fitted))
print(length(a.fitted))
print(length(f.fitted))
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]