VincyaneBadouard / TreeData_broken

Harmonization and correction forest data tool.
https://vincyanebadouard.github.io/TreeData/
0 stars 1 forks source link

PunctualErrorDetection #78

Closed ValentineHerr closed 1 year ago

ValentineHerr commented 1 year ago

@VincyaneBadouard, in your example for PunctualErrorDetection, is it normal that the function does not detect issues in the "2 shifts error case"?

> Time <- c(2000, 2002, 2004, 2006, 2008, 2012, 2014, 2016, 2020)
> 
> # 1 ind at a time
> ## Punctual error case
> DBHCor <- c(13, 14, 15, 16, 30, 19, 15, 21, 23)
> plot(Time, DBHCor)

image

> PunctualErrorDetection(DBHCor = DBHCor, Time = Time)
[1] 13 14 15 16 NA 19 NA 21 23
> ## 2 shifts error case
> DBHCor <- c(13, 14, 15, 16, 12, 14, 15, 11, 13)
> plot(Time, DBHCor)

image

> PunctualErrorDetection(DBHCor = DBHCor, Time = Time)
[1] 13 14 15 16 12 14 15 11 13
VincyaneBadouard commented 1 year ago

yes because: it's not a punctual error " @return The diameter vector (numeric) with NA instead of the punctual errors

' detected. Return the intact input diameter vector in case of shift errors."

ValentineHerr commented 1 year ago

ah oui pardon!