Skip to content

The underlying search method depends on the board, but most will search for text in the pin name and title.

Usage

pin_search(board, search = NULL, ...)

Arguments

board

A pin board, created by board_folder(), board_connect(), board_url() or another board_ function.

search

A string to search for in pin name and title. Use NULL to return all pins.

...

Additional arguments passed on to methods.

Value

A data frame that summarises the metadata for each pin. Key attributes (name, type, description, created, and file_size) are pulled out into columns; everything else can be found in the meta

list-column.

Examples

board <- board_temp()

board %>% pin_write(1:5, "x", title = "Some numbers")
#> Guessing `type = 'rds'`
#> Creating new version '20231109T175525Z-6c18b'
#> Writing to pin 'x'
board %>% pin_write(letters[c(1, 5, 10, 15, 21)], "y", title = "My favourite letters")
#> Guessing `type = 'rds'`
#> Creating new version '20231109T175525Z-312ea'
#> Writing to pin 'y'
board %>% pin_write(runif(20), "z", title = "Random numbers")
#> Guessing `type = 'rds'`
#> Creating new version '20231109T175525Z-b03f5'
#> Writing to pin 'z'

board %>% pin_search()
#> # A tibble: 3 × 6
#>   name  type  title               created             file_size meta      
#>   <chr> <chr> <chr>               <dttm>              <fs::byt> <list>    
#> 1 x     rds   Some numbers        2023-11-09 17:55:25        50 <pins_met>
#> 2 y     rds   My favourite lette… 2023-11-09 17:55:25        58 <pins_met>
#> 3 z     rds   Random numbers      2023-11-09 17:55:25       169 <pins_met>
board %>% pin_search("number")
#> # A tibble: 2 × 6
#>   name  type  title          created               file_size meta      
#>   <chr> <chr> <chr>          <dttm>              <fs::bytes> <list>    
#> 1 x     rds   Some numbers   2023-11-09 17:55:25          50 <pins_met>
#> 2 z     rds   Random numbers 2023-11-09 17:55:25         169 <pins_met>
board %>% pin_search("letters")
#> # A tibble: 1 × 6
#>   name  type  title               created             file_size meta      
#>   <chr> <chr> <chr>               <dttm>              <fs::byt> <list>    
#> 1 y     rds   My favourite lette… 2023-11-09 17:55:25        58 <pins_met>