Skip to content

Commit f431b4a

Browse files
committed
chore: switch to 100 line width
1 parent 5be35ae commit f431b4a

File tree

4 files changed

+6
-20
lines changed

4 files changed

+6
-20
lines changed

.lintr

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
linters: all_linters(
2-
line_length_linter = line_length_linter(88L),
2+
line_length_linter = line_length_linter(100L),
33
object_usage_linter = NULL,
44
todo_comment_linter = NULL,
55
strings_as_factors_linter = NULL,

R/interest-rate.R

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -247,10 +247,7 @@ tr_make_request <- function(data, date) {
247247
if (!is.null(date)) {
248248
date <- as.character(date)
249249
if (length(date) != 1L || !grepl("^\\d{4,6}$", date)) {
250-
stop(
251-
"`date` must be a single value in format yyyy or yyyymm",
252-
call. = FALSE
253-
)
250+
stop("`date` must be a single value in format yyyy or yyyymm", call. = FALSE)
254251
}
255252
} else {
256253
date <- "all"

R/yield-curve.R

Lines changed: 3 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -94,10 +94,7 @@ tr_curve_rate <- function(
9494

9595
#' @rdname tr_curve_rate
9696
#' @export
97-
tr_par_yields <- function(
98-
x = c("hqm", "tnc", "trc"),
99-
type = c("monthly", "end-of-month")
100-
) {
97+
tr_par_yields <- function(x = c("hqm", "tnc", "trc"), type = c("monthly", "end-of-month")) {
10198
if (requireNamespace("readxl", quietly = TRUE)) {
10299
stop("Please install the readxl package to use this function.", call. = FALSE)
103100
}
@@ -132,10 +129,7 @@ tr_par_yields <- function(
132129

133130
#' @rdname tr_curve_rate
134131
#' @export
135-
tr_forward_rate <- function(
136-
x = c("tnc", "trc", "tbi"),
137-
type = c("monthly", "end-of-month")
138-
) {
132+
tr_forward_rate <- function(x = c("tnc", "trc", "tbi"), type = c("monthly", "end-of-month")) {
139133
if (requireNamespace("readxl", quietly = TRUE)) {
140134
stop("Please install the readxl package to use this function.", call. = FALSE)
141135
}
@@ -168,11 +162,6 @@ download_data <- function(x, col_names, skip, names_to, values_to) {
168162
dt <- readxl::read_excel(tf, col_names = col_names, skip = skip)
169163
dt <- setDT(dt)
170164
dt[, 2L := NULL]
171-
dt <- melt(
172-
dt,
173-
id.vars = "yearmonth",
174-
variable.name = names_to,
175-
value.name = values_to
176-
)
165+
dt <- melt(dt, id.vars = "yearmonth", variable.name = names_to, value.name = values_to)
177166
dt[, yearmonth := as.Date(paste("01", yearmonth), format = "%d %B %Y")][]
178167
}

air.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
[format]
2-
line-width = 88
2+
line-width = 100

0 commit comments

Comments
 (0)