Skip to content

Rename functions (6): wl_  #309

Closed

Description

@GegznaV

This issue complements #208 (comment).

Most of the functions that directly process @wavelength should start with prefix wl_. There are several wavelength-related functions in hyperSpec that, I'm certain, should be renamed. We agreed on these:

Status Current name Suggested name Comment
✔️ orderwl wl_sort The output is more consistent with base::sort() than with base::order().
✔️ wl.eval wl_eval
✔️ wlconv wl_convert_units 1. More explicit name gives more clarity. 2. I'd like to make this function S3 generic with method for numeric, integer, and hyerSpec. 3. I'd like to rename the arguments, e.g., points → obj or x, src → from, dst → to, laser → reference_wl.
✔️ guess.wavelength extract_numbers Function is applicable not only to extract wavelengths but also numbers in general. So the new name explains the essence of the function better. Equivalent function: readr::parse_number().

Activity

  1. added
    Status: ready ✔️
    Topic: style ✏️
    on Feb 23, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Status: ready ✔️Topic: rename ♻️Topic: style ✏️

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions