Skip to content
GitLab
Projects Groups Topics Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
  • Sign in
  • CSIndicators CSIndicators
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Graph
    • Compare revisions
  • Issues 18
    • Issues 18
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 4
    • Merge requests 4
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Releases
  • Packages and registries
    • Packages and registries
    • Package Registry
    • Terraform modules
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • Earth SciencesEarth Sciences
  • CSIndicatorsCSIndicators
  • Issues
  • #52
Closed
Open
Issue created Oct 03, 2024 by vagudets@vagudetsMaintainer

CST_PeriodStandardization (and others?): Rename variable longname, but leave the varName as-is

Hi @tkariyat,

In the function CST_PeriodStandardization(), the name of the variable is modified to append the word "standardized". This should ideally be done to the longname attribute in the metadata which is supposed to give a multi-word description of the variable, as the varName should be a single word with no spaces.

In other words, here (https://earth.bsc.es/gitlab/es/csindicators/-/blob/master/R/PeriodStandardization.R#L128) and in line 136, the varName should not be modified, and instead, data$attrs$Variable$metadata[[data$attrs$Variable$varName]]$longname should be modified, if it is not NULL.

Ideally, the function should also consider the case where there are multiple variables.

I can provide data to test, or maybe you can use the CSTools sample datasets (see lonlat_pr and lonlat_temp in the CSTools documentation)

Let me know if you have any question,

Victòria

Assignee
Assign to
Time tracking