-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathREADME.Rmd
More file actions
83 lines (59 loc) · 1.77 KB
/
README.Rmd
File metadata and controls
83 lines (59 loc) · 1.77 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
---
output: github_document
---
<!-- README.md is generated from README.Rmd. Please edit that file -->
```{r, include = FALSE}
knitr::opts_chunk$set(
collapse = TRUE,
comment = "#>",
fig.path = "man/figures/README-",
out.width = "100%"
)
```
# mmints
<!-- badges: start -->
<!-- badges: end -->
The 'mmints' (Mighty Metrika Internals) package aims to automate tasks commonly used in 'shiny' applications. It primarily consists of internal functions and modules frequently utilized in other Mighty Metrika 'shiny' applications.
## Installation
You can install the released version of 'mmints' from [CRAN](https://CRAN.R-project.org):
```{r eval=FALSE}
install.packages("mmints")
```
You can install the development version of 'mmints' from [GitHub](https://github.com/) with:
```{r eval=FALSE}
# install.packages("pak")
pak::pak("mightymetrika/mmints")
```
## Example
One feature of 'mmints' is the csvUploadModule, which simplifies the process of:
1. Uploading a CSV data file
2. Displaying the variables and data types as a 'DT' data table
3. Providing functionality for editing variable types
Here's how to use the csvUploadModule:
```{r eval=FALSE}
library(mmints)
csvUpload_app <- function(){
ui <- shiny::fluidPage(
shiny::titlePanel("CSV Upload Module"),
shiny::sidebarLayout(
shiny::sidebarPanel(
csvUploadUI("data_upload")$input
),
shiny::mainPanel(
csvUploadUI("data_upload")$output
)
)
)
server <- function(input, output, session) {
data <- csvUploadServer("data_upload")
}
shiny::shinyApp(ui, server)
}
if(interactive()){
csvUpload_app()
}
```
## License
This project is licensed under the MIT License.
## Contact
For any queries or suggestions, please open an issue on the GitHub repository.