https://github.com/aphalo/photobiology
Package ‘photobiology’ defines a system of classes for storing spectral data and accompanying methods and operators. This is the core of a suite of R packages for photobiological calculations.
Science Score: 39.0%
This score indicates how likely this project is to be science-related based on various indicators:
-
○CITATION.cff file
-
✓codemeta.json file
Found codemeta.json file -
✓.zenodo.json file
Found .zenodo.json file -
✓DOI references
Found 7 DOI reference(s) in README -
○Academic publication links
-
○Committers with academic emails
-
○Institutional organization owner
-
○JOSS paper metadata
-
○Scientific vocabulary similarity
Low similarity (14.6%) to scientific vocabulary
Keywords
Repository
Package ‘photobiology’ defines a system of classes for storing spectral data and accompanying methods and operators. This is the core of a suite of R packages for photobiological calculations.
Statistics
- Stars: 6
- Watchers: 1
- Forks: 2
- Open Issues: 8
- Releases: 0
Topics
Metadata Files
README.Rmd
---
output:
github_document:
html_preview: TRUE
---
```{r, echo = FALSE}
knitr::opts_chunk$set(
fig.asp = 2/3,
collapse = TRUE,
comment = "#>",
fig.path = "man/figures/README-"
)
```
# photobiology
[](https://cran.r-project.org/package=photobiology) [](https://cran.r-project.org/web/checks/check_results_photobiology.html)
[](https://aphalo.r-universe.dev/photobiology)
[](https://github.com/aphalo/photobiology/actions)
[](https://docs.r4photobiology.info/photobiology/)
[](https://doi.org/10.32614/CRAN.package.photobiology)
Package '**photobiology**' defines a system of classes for storing spectral data and accompanying metadata. For each of these classes specialised summary methods, maths operators and functions are provided. In addition, classes for storing collections of objects of the classes for individual spectra are defined as well as 'apply' functions. Extraction and replacement operators are implemented.
Functions for calculation of the position of the sun, times of sunrise and sunset, day length and night length are also available. Starting from 'photobiology' 0.12.0 they are imported from package 'SunCalcMeeus', which is a spin-off of 'photobiology. _If you only use these functions, you can attach or load 'SunCalcMeeus' instead of 'photobiology', otherwise, the only visible change is that the on-line help is at [a separate site](https://docs.r4photobiology.info/SunCalcMeeus/)._
Functions for the estimation of evapotranspiration and the energy balance of vegetation have been migrated to package ['photobiologyPlants'](https://docs.r4photobiology.info/photobiologyPlants/) as they are related to vegetation. To use them with this version of package 'photobiology', please, add `library(photobiologyPlants)` to your code.
The package supports storage and manipulation of data for radiation quantities and for optical properties of objects and solutes, as well as response and action spectra for photobiological, photochemical and photoelectrical responses.
This package is the core of a suite of R packages for photobiological calculations described at the [r4photobiology](https://www.r4photobiology.info) web site and in the vignette [The R for Photobiology Suite](https://docs.r4photobiology.info/photobiology/articles/userguide-0-r4p-introduction.html).
## Examples
The first example shows you how to estimate solar irradiance in W/m2 under a filter. We use a measured solar spectrum and a measured filter transmission spectrum.
```{r example1, message=FALSE}
library(photobiology)
e_irrad(sun.spct * yellow_gel.spct)
```
The second example shows some simple astronomical calculations for the sun.
```{r example2}
geocode <- data.frame(lon = 0, lat = 55)
date <- lubridate::now(tzone = "UTC")
sunrise_time(date, tz = "UTC", geocode = geocode)
day_length(date, tz = "UTC", geocode = geocode)
```
## Installation
Installation of the most recent stable version from CRAN:
```{r, eval=FALSE}
install.packages("photobiology")
```
Installation of the current unstable version from R-Universe CRAN-like repository:
```{r, eval=FALSE}
install.packages('photobiology',
repos = c('https://aphalo.r-universe.dev',
'https://cloud.r-project.org'))
```
The two approaches above, automatically install dependencies.
Installation of the current unstable version from GitHub:
```{r, eval=FALSE}
# install.packages("devtools")
devtools::install_github("aphalo/photobiology")
```
Installation from GitHub sources does not automatically install dependencies. Once package 'photobiology' is installed, installation of the remaining or missing packages in the suite from CRAN (or by adding the repository information as above, also from R-Universe):
```{r, eval=FALSE}
intalled_pkgs <- installed.packages()[ , 1]
missing_pkgs <- setdiff(photobiology::r4p_pkgs, intalled_pkgs)
if (length(missing_pkgs) > 0) {
install.packages(missing_pkgs)
}
```
## Documentation
HTML documentation is available at ( ), including two *User Guides*.
News on updates to the different packages of the 'r4photobiology' suite are regularly posted at ( ).
Two articles introduce the basic ideas behind the design of the suite and describe its use: Aphalo P. J. (2015) () and Aphalo P. J. (2016) ().
A book is under preparation, and the draft is currently available at ( ).
A handbook written before the suite was developed contains useful information on the quantification and manipulation of ultraviolet and visible radiation: Aphalo, P. J., Albert, A., Björn, L. O., McLeod, A. R., Robson, T. M., & Rosenqvist, E. (Eds.) (2012) Beyond the Visible: A handbook of best practice in plant UV photobiology (1st ed., p. xxx + 174). Helsinki: University of Helsinki, Department of Biosciences, Division of Plant Biology. ISBN 978-952-10-8363-1 (PDF), 978-952-10-8362-4 (paperback). PDF file available from ().
## Contributing
Pull requests, bug reports, and feature requests are welcome at ().
## Citation
If you use this package to produce scientific or commercial publications, please cite according to:
```{r}
citation("photobiology")
```
## License
© 2012-2025 Pedro J. Aphalo ([pedro.aphalo\@helsinki.fi](mailto:pedro.aphalo@helsinki.fi){.email}). Released under the GPL, version 2 or greater. This software carries no warranty of any kind.
Owner
- Name: Pedro Aphalo
- Login: aphalo
- Kind: user
- Location: Helsinki, Finland
- Company: University of Helsinki, Organismal and Evolutionary Biology (OEB)
- Website: http://blogs.helsinki.fi/senpep-blog/
- Repositories: 13
- Profile: https://github.com/aphalo
Senior University Lecturer, Principal Investigator (Sensory Ecology of Plants, Photobiology, Crops, Forest trees, Data Analysis, Data Visualization)
GitHub Events
Total
- Issues event: 22
- Watch event: 2
- Delete event: 2
- Issue comment event: 31
- Push event: 86
- Create event: 3
Last Year
- Issues event: 22
- Watch event: 2
- Delete event: 2
- Issue comment event: 31
- Push event: 86
- Create event: 3
Committers
Last synced: over 2 years ago
Top Committers
| Name | Commits | |
|---|---|---|
| Pedro J. Aphalo | p****o@h****i | 1,057 |
| aphalo | a****o | 11 |
Committer Domains (Top 20 + Academic)
Issues and Pull Requests
Last synced: 6 months ago
All Time
- Total issues: 44
- Total pull requests: 0
- Average time to close issues: 6 months
- Average time to close pull requests: N/A
- Total issue authors: 5
- Total pull request authors: 0
- Average comments per issue: 2.45
- Average comments per pull request: 0
- Merged pull requests: 0
- Bot issues: 0
- Bot pull requests: 0
Past Year
- Issues: 11
- Pull requests: 0
- Average time to close issues: 13 days
- Average time to close pull requests: N/A
- Issue authors: 2
- Pull request authors: 0
- Average comments per issue: 1.0
- Average comments per pull request: 0
- Merged pull requests: 0
- Bot issues: 0
- Bot pull requests: 0
Top Authors
Issue Authors
- aphalo (35)
- CdeMills (3)
- putmanlab (1)
- RaulSpain (1)
- romainfrancois (1)
Pull Request Authors
Top Labels
Issue Labels
Pull Request Labels
Packages
- Total packages: 1
-
Total downloads:
- cran 1,049 last-month
- Total docker downloads: 174
- Total dependent packages: 10
- Total dependent repositories: 10
- Total versions: 53
- Total maintainers: 1
cran.r-project.org: photobiology
Photobiological Calculations
- Homepage: https://docs.r4photobiology.info/photobiology/
- Documentation: http://cran.r-project.org/web/packages/photobiology/photobiology.pdf
- License: GPL-2 | GPL-3 [expanded from: GPL (≥ 2)]
-
Latest release: 0.13.2
published 7 months ago
Rankings
Maintainers (1)
Dependencies
- R >= 3.6.0 depends
- dplyr >= 1.0.9 imports
- grDevices * imports
- lubridate >= 1.7.8 imports
- plyr >= 1.8.7 imports
- polynom >= 1.4 imports
- rlang >= 0.4.8 imports
- splus2R >= 1.3 imports
- stats * imports
- stringr >= 1.4.0 imports
- tibble >= 3.1.0 imports
- tidyr >= 1.2.0 imports
- zoo >= 1.8 imports
- knitr >= 1.30 suggests
- lutz >= 0.3.1 suggests
- rmarkdown >= 2.4 suggests
- roxygen2 >= 7.1.1 suggests
- testthat >= 2.3.2 suggests
- actions/checkout v3 composite
- r-lib/actions/check-r-package v2 composite
- r-lib/actions/setup-pandoc v2 composite
- r-lib/actions/setup-r v2 composite
- r-lib/actions/setup-r-dependencies v2 composite
- actions/checkout v2 composite
- r-lib/actions/setup-r v1 composite
- r-lib/actions/setup-r-dependencies v1 composite