Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

take min/max values instead of first/last of seq function #27

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

giyany
Copy link

@giyany giyany commented Jan 5, 2022

Fixes #12

when assigning l$pos[[i]] inside smooth.twisst, seq function seemed to pick the chronological first and last values in pos.
However, some users may produce window_data_files with columns that are not sorted (mine was sorted 'naively' on command line, hence lexicographic sorting), and the error was caused by seq recieving values in which from < to.

Using instead the min/max values in the column can fix this,
data not being sorted causes further issues, for example with plot.twisst, so a more holistic solution may be better.

Cheers, thank you for this tool!

@simonhmartin
Copy link
Owner

Thanks for the suggestion. I would prefer for users to use the existing solution, using option reorder_by_start=TRUE in the import.twisst function, because having the files out of order could break other functions and it would be less efficient to create bespoke solutions in each case.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

erro twisst_data_smooth
2 participants