Skip to content

Commit

Permalink
transition "occured" -> "occurred" (#465)
Browse files Browse the repository at this point in the history
  • Loading branch information
simonpcouch authored Dec 1, 2023
1 parent b9ea40f commit 2eb9555
Show file tree
Hide file tree
Showing 11 changed files with 31 additions and 31 deletions.
4 changes: 2 additions & 2 deletions R/class-precision.R
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,7 @@ warn_precision_undefined_binary <- function(event, count) {
paste(
"Note that",
count,
"true event(s) actually occured for the problematic event level,",
"true event(s) actually occurred for the problematic event level,",
event
)
)
Expand All @@ -208,7 +208,7 @@ warn_precision_undefined_multiclass <- function(events, counts) {
events (i.e. `true_positive + false_positive = 0`).",
"Precision is undefined in this case, and those levels will be removed \\
from the averaged result.",
"Note that the following number of true events actually occured for each \\
"Note that the following number of true events actually occurred for each \\
problematic event level:",
paste0("'", events, "': ", counts, collapse = ", ")
)
Expand Down
4 changes: 2 additions & 2 deletions R/class-recall.R
Original file line number Diff line number Diff line change
Expand Up @@ -190,7 +190,7 @@ warn_recall_undefined_binary <- function(event, count) {
paste(
"Note that",
count,
"predicted event(s) actually occured for the problematic event level",
"predicted event(s) actually occurred for the problematic event level",
event
)
)
Expand All @@ -209,7 +209,7 @@ warn_recall_undefined_multiclass <- function(events, counts) {
(i.e. `true_positive + false_negative = 0`).",
"Recall is undefined in this case, and those levels will be removed from \\
the averaged result.",
"Note that the following number of predicted events actually occured for \\
"Note that the following number of predicted events actually occurred for \\
each problematic event level:",
paste0("'", events, "': ", counts, collapse = ", ")
)
Expand Down
4 changes: 2 additions & 2 deletions R/class-sens.R
Original file line number Diff line number Diff line change
Expand Up @@ -288,7 +288,7 @@ warn_sens_undefined_binary <- function(event, count) {
paste(
"Note that",
count,
"predicted event(s) actually occured for the problematic event level,",
"predicted event(s) actually occurred for the problematic event level,",
event
)
)
Expand All @@ -307,7 +307,7 @@ warn_sens_undefined_multiclass <- function(events, counts) {
(i.e. `true_positive + false_negative = 0`).",
"Sensitivity is undefined in this case, and those levels will be removed \\
from the averaged result.",
"Note that the following number of predicted events actually occured for \\
"Note that the following number of predicted events actually occurred for \\
each problematic event level:",
paste0("'", events, "': ", counts, collapse = ", ")
)
Expand Down
4 changes: 2 additions & 2 deletions R/class-spec.R
Original file line number Diff line number Diff line change
Expand Up @@ -258,7 +258,7 @@ warn_spec_undefined_binary <- function(event, count) {
paste(
"Note that",
count,
"predicted negatives(s) actually occured for the problematic event level,",
"predicted negatives(s) actually occurred for the problematic event level,",
event
)
)
Expand All @@ -277,7 +277,7 @@ warn_spec_undefined_multiclass <- function(events, counts) {
(i.e. `true_negative + false_positive = 0`).",
"Specificity is undefined in this case, and those levels will be removed \\
from the averaged result.",
"Note that the following number of predicted negatives actually occured \\
"Note that the following number of predicted negatives actually occurred \\
for each problematic event level:",
paste0("'", events, "': ", counts, collapse = ", ")
)
Expand Down
16 changes: 8 additions & 8 deletions tests/testthat/_snaps/class-f_meas.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,14 @@
Warning:
While computing binary `precision()`, no predicted events were detected (i.e. `true_positive + false_positive = 0`).
Precision is undefined in this case, and `NA` will be returned.
Note that 2 true event(s) actually occured for the problematic event level, a
Note that 2 true event(s) actually occurred for the problematic event level, a
Code
expect <- f_meas_vec(truth, estimate)
Condition
Warning:
While computing binary `precision()`, no predicted events were detected (i.e. `true_positive + false_positive = 0`).
Precision is undefined in this case, and `NA` will be returned.
Note that 2 true event(s) actually occured for the problematic event level, a
Note that 2 true event(s) actually occurred for the problematic event level, a

# `NA` values propagate from binary `recall()`

Expand All @@ -23,14 +23,14 @@
Warning:
While computing binary `recall()`, no true events were detected (i.e. `true_positive + false_negative = 0`).
Recall is undefined in this case, and `NA` will be returned.
Note that 2 predicted event(s) actually occured for the problematic event level a
Note that 2 predicted event(s) actually occurred for the problematic event level a
Code
expect <- f_meas_vec(truth, estimate)
Condition
Warning:
While computing binary `recall()`, no true events were detected (i.e. `true_positive + false_negative = 0`).
Recall is undefined in this case, and `NA` will be returned.
Note that 2 predicted event(s) actually occured for the problematic event level a
Note that 2 predicted event(s) actually occurred for the problematic event level a

# Binary `f_meas()` returns `NA` with a warning when recall is undefined (tp + fn = 0) (#98)

Expand All @@ -40,7 +40,7 @@
Warning:
While computing binary `recall()`, no true events were detected (i.e. `true_positive + false_negative = 0`).
Recall is undefined in this case, and `NA` will be returned.
Note that 1 predicted event(s) actually occured for the problematic event level a
Note that 1 predicted event(s) actually occurred for the problematic event level a

# Binary `f_meas()` returns `NA` with a warning when precision is undefined (tp + fp = 0) (#98)

Expand All @@ -50,7 +50,7 @@
Warning:
While computing binary `precision()`, no predicted events were detected (i.e. `true_positive + false_positive = 0`).
Precision is undefined in this case, and `NA` will be returned.
Note that 1 true event(s) actually occured for the problematic event level, a
Note that 1 true event(s) actually occurred for the problematic event level, a

# Multiclass `f_meas()` returns averaged value with `NA`s removed + a warning when recall is undefined (tp + fn = 0) (#98)

Expand All @@ -60,7 +60,7 @@
Warning:
While computing multiclass `recall()`, some levels had no true events (i.e. `true_positive + false_negative = 0`).
Recall is undefined in this case, and those levels will be removed from the averaged result.
Note that the following number of predicted events actually occured for each problematic event level:
Note that the following number of predicted events actually occurred for each problematic event level:
'c': 1

# Multiclass `f_meas()` returns averaged value with `NA`s removed + a warning when precision is undefined (tp + fn = 0) (#98)
Expand All @@ -71,7 +71,7 @@
Warning:
While computing multiclass `precision()`, some levels had no predicted events (i.e. `true_positive + false_positive = 0`).
Precision is undefined in this case, and those levels will be removed from the averaged result.
Note that the following number of true events actually occured for each problematic event level:
Note that the following number of true events actually occurred for each problematic event level:
'c': 1

# work with class_pred input
Expand Down
10 changes: 5 additions & 5 deletions tests/testthat/_snaps/class-j_index.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
Warning:
While computing binary `sens()`, no true events were detected (i.e. `true_positive + false_negative = 0`).
Sensitivity is undefined in this case, and `NA` will be returned.
Note that 1 predicted event(s) actually occured for the problematic event level, a
Note that 1 predicted event(s) actually occurred for the problematic event level, a

# Binary `j_index()` returns `NA` with a warning when specificity is undefined (tn + fp = 0) (#265)

Expand All @@ -16,7 +16,7 @@
Warning:
While computing binary `spec()`, no true negatives were detected (i.e. `true_negative + false_positive = 0`).
Specificity is undefined in this case, and `NA` will be returned.
Note that 1 predicted negatives(s) actually occured for the problematic event level, a
Note that 1 predicted negatives(s) actually occurred for the problematic event level, a

# Multiclass `j_index()` returns averaged value with `NA`s removed + a warning when sensitivity is undefined (tp + fn = 0) (#265)

Expand All @@ -26,7 +26,7 @@
Warning:
While computing multiclass `sens()`, some levels had no true events (i.e. `true_positive + false_negative = 0`).
Sensitivity is undefined in this case, and those levels will be removed from the averaged result.
Note that the following number of predicted events actually occured for each problematic event level:
Note that the following number of predicted events actually occurred for each problematic event level:
'c': 1

# Multiclass `j_index()` returns averaged value with `NA`s removed + a warning when specificity is undefined (tn + fp = 0) (#265)
Expand All @@ -37,12 +37,12 @@
Warning:
While computing multiclass `sens()`, some levels had no true events (i.e. `true_positive + false_negative = 0`).
Sensitivity is undefined in this case, and those levels will be removed from the averaged result.
Note that the following number of predicted events actually occured for each problematic event level:
Note that the following number of predicted events actually occurred for each problematic event level:
'b': 1, 'c': 1
Warning:
While computing multiclass `spec()`, some levels had no true negatives (i.e. `true_negative + false_positive = 0`).
Specificity is undefined in this case, and those levels will be removed from the averaged result.
Note that the following number of predicted negatives actually occured for each problematic event level:
Note that the following number of predicted negatives actually occurred for each problematic event level:
'a': 2

# work with class_pred input
Expand Down
2 changes: 1 addition & 1 deletion tests/testthat/_snaps/class-ppv.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
Warning:
While computing binary `sens()`, no true events were detected (i.e. `true_positive + false_negative = 0`).
Sensitivity is undefined in this case, and `NA` will be returned.
Note that 1 predicted event(s) actually occured for the problematic event level, a
Note that 1 predicted event(s) actually occurred for the problematic event level, a

# work with class_pred input

Expand Down
6 changes: 3 additions & 3 deletions tests/testthat/_snaps/class-precision.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
Warning:
While computing binary `precision()`, no predicted events were detected (i.e. `true_positive + false_positive = 0`).
Precision is undefined in this case, and `NA` will be returned.
Note that 1 true event(s) actually occured for the problematic event level, a
Note that 1 true event(s) actually occurred for the problematic event level, a

# Multiclass `precision()` returns averaged value with `NA`s removed + a warning when undefined (tp + fp = 0) (#98)

Expand All @@ -16,7 +16,7 @@
Warning:
While computing multiclass `precision()`, some levels had no predicted events (i.e. `true_positive + false_positive = 0`).
Precision is undefined in this case, and those levels will be removed from the averaged result.
Note that the following number of true events actually occured for each problematic event level:
Note that the following number of true events actually occurred for each problematic event level:
'a': 1, 'b': 1, 'c': 1

---
Expand All @@ -27,7 +27,7 @@
Warning:
While computing multiclass `precision()`, some levels had no predicted events (i.e. `true_positive + false_positive = 0`).
Precision is undefined in this case, and those levels will be removed from the averaged result.
Note that the following number of true events actually occured for each problematic event level:
Note that the following number of true events actually occurred for each problematic event level:
'c': 1

# work with class_pred input
Expand Down
4 changes: 2 additions & 2 deletions tests/testthat/_snaps/class-recall.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
Warning:
While computing binary `recall()`, no true events were detected (i.e. `true_positive + false_negative = 0`).
Recall is undefined in this case, and `NA` will be returned.
Note that 1 predicted event(s) actually occured for the problematic event level a
Note that 1 predicted event(s) actually occurred for the problematic event level a

# Multiclass `recall()` returns averaged value with `NA`s removed + a warning when undefined (tp + fn = 0) (#98)

Expand All @@ -16,7 +16,7 @@
Warning:
While computing multiclass `recall()`, some levels had no true events (i.e. `true_positive + false_negative = 0`).
Recall is undefined in this case, and those levels will be removed from the averaged result.
Note that the following number of predicted events actually occured for each problematic event level:
Note that the following number of predicted events actually occurred for each problematic event level:
'b': 0, 'c': 1

# work with class_pred input
Expand Down
4 changes: 2 additions & 2 deletions tests/testthat/_snaps/class-sens.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
Warning:
While computing binary `sens()`, no true events were detected (i.e. `true_positive + false_negative = 0`).
Sensitivity is undefined in this case, and `NA` will be returned.
Note that 1 predicted event(s) actually occured for the problematic event level, a
Note that 1 predicted event(s) actually occurred for the problematic event level, a

# Multiclass `sens()` returns averaged value with `NA`s removed + a warning when undefined (tp + fn = 0) (#98)

Expand All @@ -16,7 +16,7 @@
Warning:
While computing multiclass `sens()`, some levels had no true events (i.e. `true_positive + false_negative = 0`).
Sensitivity is undefined in this case, and those levels will be removed from the averaged result.
Note that the following number of predicted events actually occured for each problematic event level:
Note that the following number of predicted events actually occurred for each problematic event level:
'b': 0, 'c': 1

# work with class_pred input
Expand Down
4 changes: 2 additions & 2 deletions tests/testthat/_snaps/class-spec.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
Warning:
While computing binary `spec()`, no true negatives were detected (i.e. `true_negative + false_positive = 0`).
Specificity is undefined in this case, and `NA` will be returned.
Note that 1 predicted negatives(s) actually occured for the problematic event level, a
Note that 1 predicted negatives(s) actually occurred for the problematic event level, a

# Multiclass `spec()` returns averaged value with `NA`s removed + a warning when undefined (tn + fp = 0) (#98)

Expand All @@ -16,7 +16,7 @@
Warning:
While computing multiclass `spec()`, some levels had no true negatives (i.e. `true_negative + false_positive = 0`).
Specificity is undefined in this case, and those levels will be removed from the averaged result.
Note that the following number of predicted negatives actually occured for each problematic event level:
Note that the following number of predicted negatives actually occurred for each problematic event level:
'a': 2

# work with class_pred input
Expand Down

0 comments on commit 2eb9555

Please sign in to comment.