diff --git a/404.html b/404.html index 5f94afd8..f0cba2a9 100644 --- a/404.html +++ b/404.html @@ -30,7 +30,7 @@ FreesearchR - 25.9.2 + 25.11.2 "; + if (ClipboardJS.isSupported()) { + $(document).ready(function () { + var copyButton = ""; - $("div.sourceCode").addClass("hasCopyButton"); + $("div.sourceCode").addClass("hasCopyButton"); - // Insert copy buttons: - $(copyButton).prependTo(".hasCopyButton"); + // Insert copy buttons: + $(copyButton).prependTo(".hasCopyButton"); - // Initialize tooltips: - $('.btn-copy-ex').tooltip({container: 'body'}); + // Initialize tooltips: + $('.btn-copy-ex').tooltip({ container: 'body' }); + + // Initialize clipboard: + var clipboard = new ClipboardJS('[data-clipboard-copy]', { + text: function (trigger) { + return trigger.parentNode.textContent.replace(/\n#>[^\n]*/g, ""); + } + }); + + clipboard.on('success', function (e) { + changeTooltipMessage(e.trigger, 'Copied!'); + e.clearSelection(); + }); + + clipboard.on('error', function (e) { + changeTooltipMessage(e.trigger, 'Press Ctrl+C or Command+C to copy'); + }); - // Initialize clipboard: - var clipboard = new ClipboardJS('[data-clipboard-copy]', { - text: function(trigger) { - return trigger.parentNode.textContent.replace(/\n#>[^\n]*/g, ""); - } }); - - clipboard.on('success', function(e) { - changeTooltipMessage(e.trigger, 'Copied!'); - e.clearSelection(); - }); - - clipboard.on('error', function(e) { - changeTooltipMessage(e.trigger,'Press Ctrl+C or Command+C to copy'); - }); - - }); - } + } /* Search marking --------------------------*/ var url = new URL(window.location.href); @@ -80,80 +80,80 @@ }); } - /* Search --------------------------*/ - /* Adapted from https://github.com/rstudio/bookdown/blob/2d692ba4b61f1e466c92e78fd712b0ab08c11d31/inst/resources/bs4_book/bs4_book.js#L25 */ + /* Search --------------------------*/ + /* Adapted from https://github.com/rstudio/bookdown/blob/2d692ba4b61f1e466c92e78fd712b0ab08c11d31/inst/resources/bs4_book/bs4_book.js#L25 */ // Initialise search index on focus - var fuse; - $("#search-input").focus(async function(e) { - if (fuse) { - return; - } + var fuse; + $("#search-input").focus(async function (e) { + if (fuse) { + return; + } - $(e.target).addClass("loading"); - var response = await fetch($("#search-input").data("search-index")); - var data = await response.json(); + $(e.target).addClass("loading"); + var response = await fetch($("#search-input").data("search-index")); + var data = await response.json(); + var options = { + keys: ["what", "text", "code"], + ignoreLocation: true, + threshold: 0.1, + includeMatches: true, + includeScore: true, + }; + fuse = new Fuse(data, options); + + $(e.target).removeClass("loading"); + }); + + // Use algolia autocomplete var options = { - keys: ["what", "text", "code"], - ignoreLocation: true, - threshold: 0.1, - includeMatches: true, - includeScore: true, + autoselect: true, + debug: true, + hint: false, + minLength: 2, }; - fuse = new Fuse(data, options); + var q; + async function searchFuse(query, callback) { + await fuse; - $(e.target).removeClass("loading"); - }); - - // Use algolia autocomplete - var options = { - autoselect: true, - debug: true, - hint: false, - minLength: 2, - }; - var q; -async function searchFuse(query, callback) { - await fuse; - - var items; - if (!fuse) { - items = []; - } else { - q = query; - var results = fuse.search(query, { limit: 20 }); - items = results - .filter((x) => x.score <= 0.75) - .map((x) => x.item); - if (items.length === 0) { - items = [{dir:"Sorry 😿",previous_headings:"",title:"No results found.",what:"No results found.",path:window.location.href}]; + var items; + if (!fuse) { + items = []; + } else { + q = query; + var results = fuse.search(query, { limit: 20 }); + items = results + .filter((x) => x.score <= 0.75) + .map((x) => x.item); + if (items.length === 0) { + items = [{ dir: "Sorry 😿", previous_headings: "", title: "No results found.", what: "No results found.", path: window.location.href }]; + } + } + callback(items); } - } - callback(items); -} - $("#search-input").autocomplete(options, [ - { - name: "content", - source: searchFuse, - templates: { - suggestion: (s) => { - if (s.title == s.what) { - return `${s.dir} >
${s.title}
`; - } else if (s.previous_headings == "") { - return `${s.dir} >
${s.title}
> ${s.what}`; - } else { - return `${s.dir} >
${s.title}
> ${s.previous_headings} > ${s.what}`; - } + $("#search-input").autocomplete(options, [ + { + name: "content", + source: searchFuse, + templates: { + suggestion: (s) => { + if (s.title == s.what) { + return `${s.dir} >
${s.title}
`; + } else if (s.previous_headings == "") { + return `${s.dir} >
${s.title}
> ${s.what}`; + } else { + return `${s.dir} >
${s.title}
> ${s.previous_headings} > ${s.what}`; + } + }, }, }, - }, - ]).on('autocomplete:selected', function(event, s) { - window.location.href = s.path + "?q=" + q + "#" + s.id; - }); + ]).on('autocomplete:selected', function (event, s) { + window.location.href = s.path + "?q=" + q + "#" + s.id; + }); }); })(window.jQuery || window.$) -document.addEventListener('keydown', function(event) { +document.addEventListener('keydown', function (event) { // Check if the pressed key is '/' if (event.key === '/') { event.preventDefault(); // Prevent any default action associated with the '/' key diff --git a/pkgdown.yml b/pkgdown.yml index 5c7d4eb8..6b315243 100644 --- a/pkgdown.yml +++ b/pkgdown.yml @@ -1,5 +1,5 @@ pandoc: 3.1.11 -pkgdown: 2.1.3 +pkgdown: 2.2.0 pkgdown_sha: ~ articles: data-types: data-types.html @@ -7,7 +7,7 @@ articles: missingness: missingness.html session: session.html visuals: visuals.html -last_built: 2025-09-24T09:52Z +last_built: 2025-11-19T13:24Z urls: reference: https://agdamsbo.github.io/FreesearchR/reference article: https://agdamsbo.github.io/FreesearchR/articles diff --git a/reference/FreesearchR_palette.html b/reference/FreesearchR_palette.html index c49cb63d..8214b28b 100644 --- a/reference/FreesearchR_palette.html +++ b/reference/FreesearchR_palette.html @@ -7,7 +7,7 @@ FreesearchR - 25.9.2 + 25.11.2 + + + + + +
+
+
+ +
+

Library of cut methods with descriptions

+
+ +
+

Usage

+
cut_methods()
+
+ +
+

Value

+

vector

+
+ +
+ + +
+ + + +
+ + + + + + + diff --git a/reference/cut_methods.md b/reference/cut_methods.md new file mode 100644 index 00000000..9be87843 --- /dev/null +++ b/reference/cut_methods.md @@ -0,0 +1,13 @@ +# Library of cut methods with descriptions + +Library of cut methods with descriptions + +## Usage + +``` r +cut_methods() +``` + +## Value + +vector diff --git a/reference/cut_var.factor.html b/reference/cut_var.factor.html new file mode 100644 index 00000000..62c61cd3 --- /dev/null +++ b/reference/cut_var.factor.html @@ -0,0 +1,8 @@ + + + + + + + + diff --git a/reference/cut_var.html b/reference/cut_var.html index bc411b99..f858cecc 100644 --- a/reference/cut_var.html +++ b/reference/cut_var.html @@ -1,5 +1,7 @@ -Extended cutting function with fall-back to the native base::cut — cut_var • FreesearchR +Extended cutting function with fall-back to the native base::cut — cut_var • FreesearchR Skip to contents @@ -7,7 +9,7 @@ FreesearchR - 25.9.2 + 25.11.2 + + + + + +
+
+
+ +
+

Accepts any repeat of delimiters and includes surrounding whitespace

+
+ +
+

Usage

+
detect_delimiter(data, delimiters = c("_", "-", ";", "\n", ","))
+
+ +
+

Arguments

+ + +
delimiters
+

allowed delimiters

+ + +
text
+

character vector

+ +
+
+

Value

+

character vector

+
+ +
+

Examples

+
sapply(c("Walk - run", "Sel__Re", "what;now"), detect_delimiter)
+#> Walk - run    Sel__Re   what;now 
+#>      " - "       "__"        ";" 
+
+
+
+ + +
+ + + +
+ + + + + + + diff --git a/reference/detect_delimiter.md b/reference/detect_delimiter.md new file mode 100644 index 00000000..ee145d90 --- /dev/null +++ b/reference/detect_delimiter.md @@ -0,0 +1,31 @@ +# Detect delimiters in string based on allowed delimiters + +Accepts any repeat of delimiters and includes surrounding whitespace + +## Usage + +``` r +detect_delimiter(data, delimiters = c("_", "-", ";", "\n", ",")) +``` + +## Arguments + +- delimiters: + + allowed delimiters + +- text: + + character vector + +## Value + +character vector + +## Examples + +``` r +sapply(c("Walk - run", "Sel__Re", "what;now"), detect_delimiter) +#> Walk - run Sel__Re what;now +#> " - " "__" ";" +``` diff --git a/reference/dim_change_call.html b/reference/dim_change_call.html index c404a25c..4a038693 100644 --- a/reference/dim_change_call.html +++ b/reference/dim_change_call.html @@ -7,7 +7,7 @@ FreesearchR - 25.9.2 + 25.11.2 + + + + + +
+
+
+ +
+

Get packages containing datasets

+
+ +
+

Usage

+
get_data_packages()
+
+ +
+

Value

+

a character vector of packages names

+
+ +
+

Examples

+
if (interactive()) {
+
+  get_data_packages()
+
+}
+
+
+
+ + +
+ + + +
+ + + + + + + diff --git a/reference/get_data_packages.md b/reference/get_data_packages.md new file mode 100644 index 00000000..6c0c2694 --- /dev/null +++ b/reference/get_data_packages.md @@ -0,0 +1,23 @@ +# Get packages containing datasets + +Get packages containing datasets + +## Usage + +``` r +get_data_packages() +``` + +## Value + +a character vector of packages names + +## Examples + +``` r +if (interactive()) { + + get_data_packages() + +} +``` diff --git a/reference/get_fun_options.html b/reference/get_fun_options.html index c7a96fbe..a3e0d21a 100644 --- a/reference/get_fun_options.html +++ b/reference/get_fun_options.html @@ -7,7 +7,7 @@ FreesearchR - 25.9.2 + 25.11.2 + + + + + +
+
+
+ +
+

General function to sub-setting details stored in list dictionaries.

+
+ +
+

Usage

+
get_list_elements(name, element, dict = cut_methods())
+
+ +
+

Arguments

+ + +
name
+

list name to lookup

+ + +
element
+

element to get

+ + +
dict
+

dictionary to use

+ +
+
+

Value

+

named vector

+
+ +
+

Examples

+
get_list_elements(c("top", "bottom"), "descr")
+#> Error in cut_methods(): object 'i18n' not found
+
+
+
+ + +
+ + + +
+ + + + + + + diff --git a/reference/get_list_elements.md b/reference/get_list_elements.md new file mode 100644 index 00000000..067e8f29 --- /dev/null +++ b/reference/get_list_elements.md @@ -0,0 +1,34 @@ +# Subset elements from list of lists + +General function to sub-setting details stored in list dictionaries. + +## Usage + +``` r +get_list_elements(name, element, dict = cut_methods()) +``` + +## Arguments + +- name: + + list name to lookup + +- element: + + element to get + +- dict: + + dictionary to use + +## Value + +named vector + +## Examples + +``` r +get_list_elements(c("top", "bottom"), "descr") +#> Error in cut_methods(): object 'i18n' not found +``` diff --git a/reference/get_plot_options.html b/reference/get_plot_options.html index 58e7a426..14e54375 100644 --- a/reference/get_plot_options.html +++ b/reference/get_plot_options.html @@ -7,7 +7,7 @@ FreesearchR - 25.9.2 + 25.11.2
+ + + + + +
+
+
+ +
+

Let the user select a dataset from its own environment or from a package's environment. +Modified from datamods

+
+ +
+

Usage

+
import_globalenv_ui(
+  id,
+  globalenv = TRUE,
+  packages = datamods::get_data_packages(),
+  title = TRUE
+)
+
+import_globalenv_server(
+  id,
+  btn_show_data = TRUE,
+  show_data_in = c("popup", "modal"),
+  trigger_return = c("button", "change"),
+  return_class = c("data.frame", "data.table", "tbl_df", "raw"),
+  reset = reactive(NULL)
+)
+
+ +
+

Arguments

+ + +
id
+

Module's ID.

+ + +
globalenv
+

Search for data in Global environment.

+ + +
packages
+

Name of packages in which to search data.

+ + +
title
+

Module's title, if TRUE use the default title, +use NULL for no title or a shiny.tag for a custom one.

+ + +
btn_show_data
+

Display or not a button to display data in a modal window if import is successful.

+ + +
show_data_in
+

Where to display data: in a "popup" or in a "modal" window.

+ + +
trigger_return
+

When to update selected data: +"button" (when user click on button) or +"change" (each time user select a dataset in the list).

+ + +
return_class
+

Class of returned data: data.frame, data.table, tbl_df (tibble) or raw.

+ + +
reset
+

A reactive function that when triggered resets the data.

+ +
+ +
+ + +
+ + + +
+ + + + + + + diff --git a/reference/import-globalenv.md b/reference/import-globalenv.md new file mode 100644 index 00000000..0d63b344 --- /dev/null +++ b/reference/import-globalenv.md @@ -0,0 +1,66 @@ +# Import data from an Environment + +Let the user select a dataset from its own environment or from a +package's environment. Modified from datamods + +## Usage + +``` r +import_globalenv_ui( + id, + globalenv = TRUE, + packages = datamods::get_data_packages(), + title = TRUE +) + +import_globalenv_server( + id, + btn_show_data = TRUE, + show_data_in = c("popup", "modal"), + trigger_return = c("button", "change"), + return_class = c("data.frame", "data.table", "tbl_df", "raw"), + reset = reactive(NULL) +) +``` + +## Arguments + +- id: + + Module's ID. + +- globalenv: + + Search for data in Global environment. + +- packages: + + Name of packages in which to search data. + +- title: + + Module's title, if `TRUE` use the default title, use `NULL` for no + title or a `shiny.tag` for a custom one. + +- btn_show_data: + + Display or not a button to display data in a modal window if import is + successful. + +- show_data_in: + + Where to display data: in a `"popup"` or in a `"modal"` window. + +- trigger_return: + + When to update selected data: `"button"` (when user click on button) + or `"change"` (each time user select a dataset in the list). + +- return_class: + + Class of returned data: `data.frame`, `data.table`, `tbl_df` (tibble) + or `raw`. + +- reset: + + A `reactive` function that when triggered resets the data. diff --git a/reference/import_globalenv_server.html b/reference/import_globalenv_server.html new file mode 100644 index 00000000..dd8be7e9 --- /dev/null +++ b/reference/import_globalenv_server.html @@ -0,0 +1,8 @@ + + + + + + + + diff --git a/reference/import_globalenv_ui.html b/reference/import_globalenv_ui.html new file mode 100644 index 00000000..dd8be7e9 --- /dev/null +++ b/reference/import_globalenv_ui.html @@ -0,0 +1,8 @@ + + + + + + + + diff --git a/reference/index.html b/reference/index.html index cbbb62de..d523c23a 100644 --- a/reference/index.html +++ b/reference/index.html @@ -7,7 +7,7 @@ FreesearchR - 25.9.2 + 25.11.2 + + + + + +
+
+
+ +
+

Determine if any variable in data frame character and contains recognized delimiters

+
+ +
+

Usage

+
is_splittable(data)
+
+ +
+

Arguments

+ + +
data
+

vector or data.frame

+ +
+
+

Value

+

logical

+
+ +
+

Examples

+
any(apply(mtcars, 2, is_splittable))
+#> [1] FALSE
+is_splittable(mtcars)
+#>   mpg   cyl  disp    hp  drat    wt  qsec    vs    am  gear  carb 
+#> FALSE FALSE FALSE FALSE FALSE FALSE FALSE FALSE FALSE FALSE FALSE 
+
+
+
+ + +
+ + + +
+ + + + + + + diff --git a/reference/is_splittable.md b/reference/is_splittable.md new file mode 100644 index 00000000..5a55c49d --- /dev/null +++ b/reference/is_splittable.md @@ -0,0 +1,30 @@ +# Determine if any variable in data frame character and contains recognized delimiters + +Determine if any variable in data frame character and contains +recognized delimiters + +## Usage + +``` r +is_splittable(data) +``` + +## Arguments + +- data: + + vector or data.frame + +## Value + +logical + +## Examples + +``` r +any(apply(mtcars, 2, is_splittable)) +#> [1] FALSE +is_splittable(mtcars) +#> mpg cyl disp hp drat wt qsec vs am gear carb +#> FALSE FALSE FALSE FALSE FALSE FALSE FALSE FALSE FALSE FALSE FALSE +``` diff --git a/reference/is_valid_redcap_url.html b/reference/is_valid_redcap_url.html index 9cb6a71e..ee50d38d 100644 --- a/reference/is_valid_redcap_url.html +++ b/reference/is_valid_redcap_url.html @@ -7,7 +7,7 @@ FreesearchR - 25.9.2 + 25.11.2 + + + + + +
+
+
+ +
+

This function may act to guard a hosted app against very large data sets in +addition to the file size limitations. +The function will limit the data set by dropping rows.

+
+ +
+

Usage

+
limit_data_size(data, limit = NULL)
+
+ +
+

Arguments

+ + +
data
+

data.frame

+ + +
limit
+

cell number limit. Default is NULL.

+ +
+
+

Value

+

data.frame

+
+ +
+

Examples

+
prod(dim(mtcars))
+#> [1] 352
+limit_data_size(mtcars)
+#>                      mpg cyl  disp  hp drat    wt  qsec vs am gear carb
+#> Mazda RX4           21.0   6 160.0 110 3.90 2.620 16.46  0  1    4    4
+#> Mazda RX4 Wag       21.0   6 160.0 110 3.90 2.875 17.02  0  1    4    4
+#> Datsun 710          22.8   4 108.0  93 3.85 2.320 18.61  1  1    4    1
+#> Hornet 4 Drive      21.4   6 258.0 110 3.08 3.215 19.44  1  0    3    1
+#> Hornet Sportabout   18.7   8 360.0 175 3.15 3.440 17.02  0  0    3    2
+#> Valiant             18.1   6 225.0 105 2.76 3.460 20.22  1  0    3    1
+#> Duster 360          14.3   8 360.0 245 3.21 3.570 15.84  0  0    3    4
+#> Merc 240D           24.4   4 146.7  62 3.69 3.190 20.00  1  0    4    2
+#> Merc 230            22.8   4 140.8  95 3.92 3.150 22.90  1  0    4    2
+#> Merc 280            19.2   6 167.6 123 3.92 3.440 18.30  1  0    4    4
+#> Merc 280C           17.8   6 167.6 123 3.92 3.440 18.90  1  0    4    4
+#> Merc 450SE          16.4   8 275.8 180 3.07 4.070 17.40  0  0    3    3
+#> Merc 450SL          17.3   8 275.8 180 3.07 3.730 17.60  0  0    3    3
+#> Merc 450SLC         15.2   8 275.8 180 3.07 3.780 18.00  0  0    3    3
+#> Cadillac Fleetwood  10.4   8 472.0 205 2.93 5.250 17.98  0  0    3    4
+#> Lincoln Continental 10.4   8 460.0 215 3.00 5.424 17.82  0  0    3    4
+#> Chrysler Imperial   14.7   8 440.0 230 3.23 5.345 17.42  0  0    3    4
+#> Fiat 128            32.4   4  78.7  66 4.08 2.200 19.47  1  1    4    1
+#> Honda Civic         30.4   4  75.7  52 4.93 1.615 18.52  1  1    4    2
+#> Toyota Corolla      33.9   4  71.1  65 4.22 1.835 19.90  1  1    4    1
+#> Toyota Corona       21.5   4 120.1  97 3.70 2.465 20.01  1  0    3    1
+#> Dodge Challenger    15.5   8 318.0 150 2.76 3.520 16.87  0  0    3    2
+#> AMC Javelin         15.2   8 304.0 150 3.15 3.435 17.30  0  0    3    2
+#> Camaro Z28          13.3   8 350.0 245 3.73 3.840 15.41  0  0    3    4
+#> Pontiac Firebird    19.2   8 400.0 175 3.08 3.845 17.05  0  0    3    2
+#> Fiat X1-9           27.3   4  79.0  66 4.08 1.935 18.90  1  1    4    1
+#> Porsche 914-2       26.0   4 120.3  91 4.43 2.140 16.70  0  1    5    2
+#> Lotus Europa        30.4   4  95.1 113 3.77 1.513 16.90  1  1    5    2
+#> Ford Pantera L      15.8   8 351.0 264 4.22 3.170 14.50  0  1    5    4
+#> Ferrari Dino        19.7   6 145.0 175 3.62 2.770 15.50  0  1    5    6
+#> Maserati Bora       15.0   8 301.0 335 3.54 3.570 14.60  0  1    5    8
+#> Volvo 142E          21.4   4 121.0 109 4.11 2.780 18.60  1  1    4    2
+limit_data_size(mtcars,100)
+#>                    mpg cyl  disp  hp drat    wt  qsec vs am gear carb
+#> Mazda RX4         21.0   6 160.0 110 3.90 2.620 16.46  0  1    4    4
+#> Mazda RX4 Wag     21.0   6 160.0 110 3.90 2.875 17.02  0  1    4    4
+#> Datsun 710        22.8   4 108.0  93 3.85 2.320 18.61  1  1    4    1
+#> Hornet 4 Drive    21.4   6 258.0 110 3.08 3.215 19.44  1  0    3    1
+#> Hornet Sportabout 18.7   8 360.0 175 3.15 3.440 17.02  0  0    3    2
+#> Valiant           18.1   6 225.0 105 2.76 3.460 20.22  1  0    3    1
+#> Duster 360        14.3   8 360.0 245 3.21 3.570 15.84  0  0    3    4
+#> Merc 240D         24.4   4 146.7  62 3.69 3.190 20.00  1  0    4    2
+#> Merc 230          22.8   4 140.8  95 3.92 3.150 22.90  1  0    4    2
+
+
+
+ + +
+ + + +
+ + + + + + + diff --git a/reference/limit_data_size.md b/reference/limit_data_size.md new file mode 100644 index 00000000..242f92f1 --- /dev/null +++ b/reference/limit_data_size.md @@ -0,0 +1,77 @@ +# Limit the allowed data set size by number of cells + +This function may act to guard a hosted app against very large data sets +in addition to the file size limitations. The function will limit the +data set by dropping rows. + +## Usage + +``` r +limit_data_size(data, limit = NULL) +``` + +## Arguments + +- data: + + data.frame + +- limit: + + cell number limit. Default is NULL. + +## Value + +data.frame + +## Examples + +``` r +prod(dim(mtcars)) +#> [1] 352 +limit_data_size(mtcars) +#> mpg cyl disp hp drat wt qsec vs am gear carb +#> Mazda RX4 21.0 6 160.0 110 3.90 2.620 16.46 0 1 4 4 +#> Mazda RX4 Wag 21.0 6 160.0 110 3.90 2.875 17.02 0 1 4 4 +#> Datsun 710 22.8 4 108.0 93 3.85 2.320 18.61 1 1 4 1 +#> Hornet 4 Drive 21.4 6 258.0 110 3.08 3.215 19.44 1 0 3 1 +#> Hornet Sportabout 18.7 8 360.0 175 3.15 3.440 17.02 0 0 3 2 +#> Valiant 18.1 6 225.0 105 2.76 3.460 20.22 1 0 3 1 +#> Duster 360 14.3 8 360.0 245 3.21 3.570 15.84 0 0 3 4 +#> Merc 240D 24.4 4 146.7 62 3.69 3.190 20.00 1 0 4 2 +#> Merc 230 22.8 4 140.8 95 3.92 3.150 22.90 1 0 4 2 +#> Merc 280 19.2 6 167.6 123 3.92 3.440 18.30 1 0 4 4 +#> Merc 280C 17.8 6 167.6 123 3.92 3.440 18.90 1 0 4 4 +#> Merc 450SE 16.4 8 275.8 180 3.07 4.070 17.40 0 0 3 3 +#> Merc 450SL 17.3 8 275.8 180 3.07 3.730 17.60 0 0 3 3 +#> Merc 450SLC 15.2 8 275.8 180 3.07 3.780 18.00 0 0 3 3 +#> Cadillac Fleetwood 10.4 8 472.0 205 2.93 5.250 17.98 0 0 3 4 +#> Lincoln Continental 10.4 8 460.0 215 3.00 5.424 17.82 0 0 3 4 +#> Chrysler Imperial 14.7 8 440.0 230 3.23 5.345 17.42 0 0 3 4 +#> Fiat 128 32.4 4 78.7 66 4.08 2.200 19.47 1 1 4 1 +#> Honda Civic 30.4 4 75.7 52 4.93 1.615 18.52 1 1 4 2 +#> Toyota Corolla 33.9 4 71.1 65 4.22 1.835 19.90 1 1 4 1 +#> Toyota Corona 21.5 4 120.1 97 3.70 2.465 20.01 1 0 3 1 +#> Dodge Challenger 15.5 8 318.0 150 2.76 3.520 16.87 0 0 3 2 +#> AMC Javelin 15.2 8 304.0 150 3.15 3.435 17.30 0 0 3 2 +#> Camaro Z28 13.3 8 350.0 245 3.73 3.840 15.41 0 0 3 4 +#> Pontiac Firebird 19.2 8 400.0 175 3.08 3.845 17.05 0 0 3 2 +#> Fiat X1-9 27.3 4 79.0 66 4.08 1.935 18.90 1 1 4 1 +#> Porsche 914-2 26.0 4 120.3 91 4.43 2.140 16.70 0 1 5 2 +#> Lotus Europa 30.4 4 95.1 113 3.77 1.513 16.90 1 1 5 2 +#> Ford Pantera L 15.8 8 351.0 264 4.22 3.170 14.50 0 1 5 4 +#> Ferrari Dino 19.7 6 145.0 175 3.62 2.770 15.50 0 1 5 6 +#> Maserati Bora 15.0 8 301.0 335 3.54 3.570 14.60 0 1 5 8 +#> Volvo 142E 21.4 4 121.0 109 4.11 2.780 18.60 1 1 4 2 +limit_data_size(mtcars,100) +#> mpg cyl disp hp drat wt qsec vs am gear carb +#> Mazda RX4 21.0 6 160.0 110 3.90 2.620 16.46 0 1 4 4 +#> Mazda RX4 Wag 21.0 6 160.0 110 3.90 2.875 17.02 0 1 4 4 +#> Datsun 710 22.8 4 108.0 93 3.85 2.320 18.61 1 1 4 1 +#> Hornet 4 Drive 21.4 6 258.0 110 3.08 3.215 19.44 1 0 3 1 +#> Hornet Sportabout 18.7 8 360.0 175 3.15 3.440 17.02 0 0 3 2 +#> Valiant 18.1 6 225.0 105 2.76 3.460 20.22 1 0 3 1 +#> Duster 360 14.3 8 360.0 245 3.21 3.570 15.84 0 0 3 4 +#> Merc 240D 24.4 4 146.7 62 3.69 3.190 20.00 1 0 4 2 +#> Merc 230 22.8 4 140.8 95 3.92 3.150 22.90 1 0 4 2 +``` diff --git a/reference/limit_log.html b/reference/limit_log.html index 707ad5ed..391fe803 100644 --- a/reference/limit_log.html +++ b/reference/limit_log.html @@ -7,7 +7,7 @@ FreesearchR - 25.9.2 + 25.11.2 + + + + + +
+
+
+ +
+

List dataset contained in a package

+
+ +
+

Usage

+
list_pkg_data(pkg)
+
+ +
+

Arguments

+ + +
pkg
+

Name of the package, must be installed.

+ +
+
+

Value

+

a character vector or NULL.

+
+ +
+

Examples

+

+list_pkg_data("ggplot2")
+#>  [1] "diamonds"       "economics"      "economics_long" "faithfuld"     
+#>  [5] "luv_colours"    "midwest"        "mpg"            "msleep"        
+#>  [9] "presidential"   "seals"          "txhousing"     
+#> attr(,"package")
+#> [1] "ggplot2"
+
+
+
+ + +
+ + + +
+ + + + + + + diff --git a/reference/list_pkg_data.md b/reference/list_pkg_data.md new file mode 100644 index 00000000..398b6c8b --- /dev/null +++ b/reference/list_pkg_data.md @@ -0,0 +1,30 @@ +# List dataset contained in a package + +List dataset contained in a package + +## Usage + +``` r +list_pkg_data(pkg) +``` + +## Arguments + +- pkg: + + Name of the package, must be installed. + +## Value + +a `character` vector or `NULL`. + +## Examples + +``` r +list_pkg_data("ggplot2") +#> [1] "diamonds" "economics" "economics_long" "faithfuld" +#> [5] "luv_colours" "midwest" "mpg" "msleep" +#> [9] "presidential" "seals" "txhousing" +#> attr(,"package") +#> [1] "ggplot2" +``` diff --git a/reference/make_validation.html b/reference/make_validation.html index 45052147..bf7b57a2 100644 --- a/reference/make_validation.html +++ b/reference/make_validation.html @@ -7,7 +7,7 @@ FreesearchR - 25.9.2 + 25.11.2 - - - - - -
-
-
- -
-

Plot missings and class with apexcharter

-
- -
-

Usage

-
missings_apex_plot(data, animation = FALSE, ...)
-
- -
-

Arguments

- - -
data
-

data frame

- -
-
-

Value

-

An apexchart() htmlwidget object.

-
- -
-

Examples

-
data_demo <- mtcars
-data_demo[2:4, "cyl"] <- NA
-rbind(data_demo, data_demo, data_demo, data_demo) |> missings_apex_plot()
-
-data_demo |> missings_apex_plot() -
-mtcars |> missings_apex_plot(animation = TRUE) -
-# dplyr::storms |> missings_apex_plot() -visdat::vis_dat(dplyr::storms) -#> Error in loadNamespace(x): there is no package called ‘visdat’ -
-
-
- - -
- - - -
- - - - - - + + + + + + + diff --git a/reference/missings_validate.html b/reference/missings_validate.html index 1e4a6a0b..6de090bf 100644 --- a/reference/missings_validate.html +++ b/reference/missings_validate.html @@ -7,7 +7,7 @@ FreesearchR - 25.9.2 + 25.11.2 + + + + + +
+
+
+ +
+

Set values as names and names as values

+
+ +
+

Usage

+
names2val(data)
+
+ +
+

Arguments

+ + +
data
+

data

+ +
+
+

Value

+

named vector

+
+ +
+

Examples

+
names2val(c("Cylinders" = "cyl", "Transmission" = "am", "Gears" = "gear"))
+#>            cyl             am           gear 
+#>    "Cylinders" "Transmission"        "Gears" 
+
+
+
+ + +
+ + + +
+ + + + + + + diff --git a/reference/names2val.md b/reference/names2val.md new file mode 100644 index 00000000..1a5a6c4e --- /dev/null +++ b/reference/names2val.md @@ -0,0 +1,27 @@ +# Set values as names and names as values + +Set values as names and names as values + +## Usage + +``` r +names2val(data) +``` + +## Arguments + +- data: + + data + +## Value + +named vector + +## Examples + +``` r +names2val(c("Cylinders" = "cyl", "Transmission" = "am", "Gears" = "gear")) +#> cyl am gear +#> "Cylinders" "Transmission" "Gears" +``` diff --git a/reference/obs_filter_validate.html b/reference/obs_filter_validate.html index 85198311..57a4d155 100644 --- a/reference/obs_filter_validate.html +++ b/reference/obs_filter_validate.html @@ -7,7 +7,7 @@ FreesearchR - 25.9.2 + 25.11.2 + + + + + +
+
+
+ +
+

Separate string wide or long

+
+ +
+

Usage

+
separate_string(data, col, delim, direction = c("wide", "long"))
+
+ +
+

Arguments

+ + +
data
+

data

+ + +
col
+

column

+ + +
delim
+

delimiter

+ + +
direction
+

target direction

+ +
+
+

Value

+

data.frame

+
+ +
+ + +
+ + + +
+ + + + + + + diff --git a/reference/separate_string.md b/reference/separate_string.md new file mode 100644 index 00000000..a16fddbe --- /dev/null +++ b/reference/separate_string.md @@ -0,0 +1,31 @@ +# Separate string wide or long + +Separate string wide or long + +## Usage + +``` r +separate_string(data, col, delim, direction = c("wide", "long")) +``` + +## Arguments + +- data: + + data + +- col: + + column + +- delim: + + delimiter + +- direction: + + target direction + +## Value + +data.frame diff --git a/reference/set_column_label.html b/reference/set_column_label.html index 7329f606..483db77e 100644 --- a/reference/set_column_label.html +++ b/reference/set_column_label.html @@ -7,7 +7,7 @@ FreesearchR - 25.9.2 + 25.11.2 + + + + + +
+
+
+ +
+

String split module based on tidyr::separate_

+
+ +
+

Usage

+
string_split_ui(id)
+
+string_split_server(id, data_r = reactive(NULL))
+
+modal_string_split(
+  id,
+  title = i18n$t("Split character string"),
+  easyClose = TRUE,
+  size = "xl",
+  footer = NULL
+)
+
+ +
+

Arguments

+ + +
id
+

id

+ + +
data_r
+

reactive data

+ + +
title
+

Modal title

+ + +
easyClose
+

easyClose

+ + +
size
+

size

+ + + +

footer

+ +
+
+

Value

+

A shiny ui module

+

shiny module server

+

shiny modal

+
+ +
+ + +
+ + + +
+ + + + + + + diff --git a/reference/split-string.md b/reference/split-string.md new file mode 100644 index 00000000..d6d06606 --- /dev/null +++ b/reference/split-string.md @@ -0,0 +1,53 @@ +# String split module based on tidyr::separate\_ + +String split module based on tidyr::separate\_ + +## Usage + +``` r +string_split_ui(id) + +string_split_server(id, data_r = reactive(NULL)) + +modal_string_split( + id, + title = i18n$t("Split character string"), + easyClose = TRUE, + size = "xl", + footer = NULL +) +``` + +## Arguments + +- id: + + id + +- data_r: + + reactive data + +- title: + + Modal title + +- easyClose: + + easyClose + +- size: + + size + +- footer: + + footer + +## Value + +A shiny ui module + +shiny module server + +shiny modal diff --git a/reference/string_split_server.html b/reference/string_split_server.html new file mode 100644 index 00000000..651af262 --- /dev/null +++ b/reference/string_split_server.html @@ -0,0 +1,8 @@ + + + + + + + + diff --git a/reference/string_split_ui.html b/reference/string_split_ui.html new file mode 100644 index 00000000..651af262 --- /dev/null +++ b/reference/string_split_ui.html @@ -0,0 +1,8 @@ + + + + + + + + diff --git a/reference/subset_types.html b/reference/subset_types.html index 65450e5a..f3d9cecc 100644 --- a/reference/subset_types.html +++ b/reference/subset_types.html @@ -7,7 +7,7 @@ FreesearchR - 25.9.2 + 25.11.2 + + + + + +
+
+
+ +
+

Data correlations evaluation module

+

Visual summary server

+

Visual summary modal

+

Plot missings and class with apexcharter. Not in use with FreesearchR.

+

Ggplot2 data summary visualisation based on visdat::vis_dat.

+
+ +
+

Usage

+
visual_summary_ui(id)
+
+visual_summary_server(id, data_r = shiny::reactive(NULL), ...)
+
+modal_visual_summary(
+  id,
+  title = "Visual overview of data classes and missing observations",
+  easyClose = TRUE,
+  size = "xl",
+  footer = NULL,
+  ...
+)
+
+missings_apex_plot(data, animation = FALSE, ...)
+
+visual_summary(data, legend.title = NULL, ylab = "Observations", ...)
+
+ +
+

Arguments

+ + +
id
+

id

+ + +
data_r
+

reactive data

+ + +
...
+

optional arguments passed to data_summary_gather()

+ + +
title
+

title

+ + +
easyClose
+

easyClose

+ + +
size
+

modal size

+ + + +

modal footer

+ + +
data
+

data

+ + +
legend.title
+

Legend title

+ + +
ylab
+

Y axis label

+ +
+
+

Value

+

Shiny ui module

+

shiny server

+

shiny modal

+

An apexchart() htmlwidget object.

+

ggplot2 object

+
+ +
+ + +
+ + + +
+ + + + + + + diff --git a/reference/visual-summary.md b/reference/visual-summary.md new file mode 100644 index 00000000..2c56fc86 --- /dev/null +++ b/reference/visual-summary.md @@ -0,0 +1,86 @@ +# Data correlations evaluation module + +Data correlations evaluation module + +Visual summary server + +Visual summary modal + +Plot missings and class with apexcharter. Not in use with FreesearchR. + +Ggplot2 data summary visualisation based on visdat::vis_dat. + +## Usage + +``` r +visual_summary_ui(id) + +visual_summary_server(id, data_r = shiny::reactive(NULL), ...) + +modal_visual_summary( + id, + title = "Visual overview of data classes and missing observations", + easyClose = TRUE, + size = "xl", + footer = NULL, + ... +) + +missings_apex_plot(data, animation = FALSE, ...) + +visual_summary(data, legend.title = NULL, ylab = "Observations", ...) +``` + +## Arguments + +- id: + + id + +- data_r: + + reactive data + +- ...: + + optional arguments passed to data_summary_gather() + +- title: + + title + +- easyClose: + + easyClose + +- size: + + modal size + +- footer: + + modal footer + +- data: + + data + +- legend.title: + + Legend title + +- ylab: + + Y axis label + +## Value + +Shiny ui module + +shiny server + +shiny modal + +An `apexchart()` `htmlwidget` object. + +ggplot2 object diff --git a/reference/visual_summary.html b/reference/visual_summary.html index 0f255864..00e34e9f 100644 --- a/reference/visual_summary.html +++ b/reference/visual_summary.html @@ -1,105 +1,8 @@ - -Ggplot2 data summary visualisation based on visdat::vis_dat. — visual_summary • FreesearchR - Skip to contents - - -
-
-
- -
-

Ggplot2 data summary visualisation based on visdat::vis_dat.

-
- -
-

Usage

-
visual_summary(data, legend.title = "Data class", ...)
-
- -
-

Arguments

- - -
data
-

data

- - -
...
-

optional arguments passed to data_summary_gather()

- -
-
-

Value

-

ggplot2 object

-
- -
-

Examples

-
data_demo <- mtcars
-data_demo[sample(1:32, 10), "cyl"] <- NA
-data_demo[sample(1:32, 8), "vs"] <- NA
-visual_summary(data_demo)
-
-visual_summary(data_demo, palette.fun = scales::hue_pal())
-
-visual_summary(dplyr::storms)
-
-visual_summary(dplyr::storms, summary.fun = data_type)
-
-
-
-
- - -
- - - -
- - - - - - + + + + + + + diff --git a/reference/visual_summary_server.html b/reference/visual_summary_server.html new file mode 100644 index 00000000..00e34e9f --- /dev/null +++ b/reference/visual_summary_server.html @@ -0,0 +1,8 @@ + + + + + + + + diff --git a/reference/visual_summary_ui.html b/reference/visual_summary_ui.html index 9a2ecac6..00e34e9f 100644 --- a/reference/visual_summary_ui.html +++ b/reference/visual_summary_ui.html @@ -1,8 +1,8 @@ - + - + diff --git a/reference/wide2long.html b/reference/wide2long.html index a9ea7dbf..b4638b89 100644 --- a/reference/wide2long.html +++ b/reference/wide2long.html @@ -11,7 +11,7 @@ an added "ignore" string pattern or similarly. Example 2.'>FreesearchR - 25.9.2 + 25.11.2