| Type: | Package |
| Title: | Read and Write 'GraphPad Prism' Files |
| Version: | 0.3.1 |
| Description: | Read and write 'GraphPad Prism' '.pzfx' files in R. |
| URL: | https://github.com/Yue-Jiang/pzfx |
| BugReports: | https://github.com/Yue-Jiang/pzfx/issues |
| Imports: | xml2 (≥ 1.2.0) |
| License: | MIT + file LICENSE |
| Encoding: | UTF-8 |
| RoxygenNote: | 7.3.3 |
| Suggests: | testthat, knitr, rmarkdown |
| VignetteBuilder: | knitr |
| NeedsCompilation: | no |
| Packaged: | 2026-01-16 05:34:03 UTC; yue.jiang |
| Author: | Yue Jiang |
| Maintainer: | Yue Jiang <rivehill@gmail.com> |
| Repository: | CRAN |
| Date/Publication: | 2026-01-16 12:20:06 UTC |
List all tables in a 'GraphPad Prism' '.pzfx' file.
Description
List all tables in a 'GraphPad Prism' '.pzfx' file.
Usage
pzfx_tables(path)
Arguments
path |
Path to the '.pzfx' file |
Value
a character string vector
Examples
pzfx_file <- system.file("extdata/exponential_decay.pzfx", package = "pzfx", mustWork = TRUE)
pzfx_tables(pzfx_file)
Read one table from a 'GraphPad Prism' '.pzfx' file
Description
Read one table from a 'GraphPad Prism' '.pzfx' file
Usage
read_pzfx(path, table = 1, strike_action = "exclude", date_x = "character")
Arguments
path |
Path to the '.pzfx' file. |
table |
Table to read. Either a string (the name of a table), or an integer (the position of the table). If neither argument specifies the table, defaults to the first table. |
strike_action |
One of c("exclude", "keep", "star") or c("e", "k", "s"). Should stricken values in the original .pzfx be excluded, kept or labeled with a trailing "*". If a trailing "*" is added, the column will be of type character. |
date_x |
One of c("numeric", "character", "both") or c("n", "c", "b"). Should x column of format "Date" be handled as numeric (time elapsed from the first time point), character (the date string encoded by Prism, for example "8-Sep-2008"), or both (leading to two columns). |
Value
a data frame
Examples
pzfx_file <- system.file("extdata/exponential_decay.pzfx", package = "pzfx", mustWork = TRUE)
read_pzfx(pzfx_file, table = 1, strike_action="exclude", date_x="character")
Write one or more tables to a GraphPad Prism .pzfx file
Description
All parameters except path and notes can be of length 1, or the length of the list of input tables.
Usage
write_pzfx(
x,
path,
row_names = TRUE,
x_col = NA,
x_err = NA,
n_digits = 2,
notes = NA,
subcolumns = 1,
subcolumn_suffix = ""
)
Arguments
x |
Data frame or named list of data frames to include as Prism tables. |
path |
Path to output file. |
row_names |
Logical or logical vector: include row names as row titles? |
x_col |
Column index or name(s) for X column (0 or NA for none). |
x_err |
Column index or name(s) for X error (0 or NA for none). |
n_digits |
Number of decimal places to display for numeric data. Default: 2. |
notes |
Notes table(s) with columns Name and Value. Default: NA (empty notes). |
subcolumns |
Number of subcolumns for Y data, or "SDN" for mean/SD/N format. Default: 1. |
subcolumn_suffix |
Regex or string identifying grouped subcolumns (e.g., "_[0-9]+$" to group A_1, A_2 as column A). Default: "" (no grouping). |
Value
Invisibly returns 'x'.