Skip to content

If *isic* is numeric we should throw a warning or error #102

@maurolepore

Description

@maurolepore

Relates to https://github.com/2DegreesInvesting/tiltIndicatorBefore/pull/69
Relates to 2DegreesInvesting/tiltIndicator#636

Now we expect single quotes around values of *isic*. This should nudge all reading functions to interpret *isic* as a character and protect leading zeroes.

If the user passes a dataset where *isic* is numeric, then we should throw a warning like this:

rlang::warn(c(
  "`*isic_4digit` should be a character but it's numeric.",
  i = "Are you using outdated data?"
))
#> Warning: `*isic_4digit` should be a character but it's numeric.
#> ℹ Are you using outdated data?

Created on 2023-12-06 with reprex v2.0.2

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions