Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/tjmahr/polypoly

Helper functions for orthogonal polynomials in R
https://github.com/tjmahr/polypoly

data-science r statistics

Last synced: about 1 month ago
JSON representation

Helper functions for orthogonal polynomials in R

Awesome Lists containing this project

README

        

---
output: github_document
---

```{r, echo = FALSE}
knitr::opts_chunk$set(
collapse = TRUE,
comment = "#>",
fig.path = "man/figures/README-"
)
```

```{r logo, message = FALSE, echo = FALSE, fig.asp=.2, dpi=600, fig.width = 8}
library(ggplot2)
x <- poly(1:10000, degree = 6)
df <- polypoly::poly_melt(x)
df$dg <- as.numeric(df$degree)
ggplot(df) +
aes(x = observation, y = value, color = dg, group = dg) +
geom_line(size = 1) +
viridis::scale_color_viridis(option = "viridis") +
theme_void() +
guides(color = "none") +
coord_cartesian(xlim = NULL, ylim = NULL, expand = FALSE)
```

# polypoly

[![CRAN_Status_Badge](http://www.r-pkg.org/badges/version/polypoly)](https://cran.r-project.org/package=polypoly)
[![R-CMD-check](https://github.com/tjmahr/polypoly/actions/workflows/R-CMD-check.yaml/badge.svg)](https://github.com/tjmahr/polypoly/actions/workflows/R-CMD-check.yaml)

Helper functions for polynomials created by `poly()`.

## Installation

Install the latest release of polypoly from CRAN:

```{r cran-installation, eval = FALSE}
install.packages("polypoly")
```

Or install the developmental version from Github:

```{r gh-installation, eval = FALSE}
# install.packages("devtools")
devtools::install_github("tjmahr/polypoly")
```

```{r, child = "vignettes/overview.Rmd"}
```