Package 'tableguess'

Title: Find Tables in Plain Text
Description: The goal of tableguess is to automatically extract table-like objects out of plain text files.
Authors: Jon Harmon [aut, cre]
Maintainer: Jon Harmon <[email protected]>
License: MIT + file LICENSE
Version: 0.0.0.9000
Built: 2024-10-27 03:33:26 UTC
Source: https://github.com/jonthegeek/tableguess

Help Index


Extract a table from a character vector

Description

This is likely not the final form and/or name of this function. Right now it requires a character vector that has already been split by newlines, and some guidance on what to do. It does well once you tell it where to look, though.

Usage

extract_table(
  tbl_vctr = character(),
  merge_empty = TRUE,
  orientation = c("horizontal", "vertical")
)

Arguments

tbl_vctr

A character vector with one line of text per value.

merge_empty

Whether to merge empty cells together (by "row" then by "column").

orientation

Whether the data is laid out horizontally like a tidy table (variables = column names), or vertically (more like a list).

Value

A data.frame with the extracted table.