This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# production | |
dbConnect( | |
RSQLServer::SQLServer(), | |
server = config$server, | |
database = config$database, | |
properties = list( | |
user = config$uid, | |
password = config$pwd | |
) | |
) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
library(ggplot2) | |
library(plotly) | |
data <- data.frame(x = rnorm(20), y = runif(20), z = letters[1:20]) | |
p <- ggplot(data, aes(x = x, y = y)) + | |
geom_smooth(method='lm') + | |
geom_point(aes(text = z)) + | |
scale_x_continuous(limits = c(0, 5)) + | |
annotate("text", label = "foo", x=1, y=1) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Connecting using RPostgreSQL works | |
library(RPostgreSQL) | |
con <- dbConnect(dbDriver("PostgreSQL"), | |
host = "localhost", | |
dbname = "postgres", | |
user = "postgres", | |
password = password, | |
port = 5432) | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
## foo `bar` | |
hello | |
``` | |
x <- 5 | |
``` | |
<p align="center">test</p> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[{"CountryList": ["Austria", "Germany", "Italy", "Spain", "United Kingdom"], "Sector3": "Commercial Leases"}, {"CountryList": ["Belgium", "France", "Germany", "Ireland", "Italy", "Netherlands", "Portugal", "Spain", "United Kingdom"], "Sector3": "Residential Mortgage"}, {"CountryList": ["Belgium", "France", "Ireland", "Spain", "United Kingdom"], "Sector3": "Credit Card"}, {"CountryList": ["Belgium", "Germany", "Italy", "Portugal", "Spain"], "Sector3": "SME CLO"}, {"CountryList": ["France", "Germany", "Netherlands"], "Sector3": "Auto Leases"}, {"CountryList": ["France", "Germany", "Italy", "Netherlands", "Norway", "Portugal", "Spain", "United Kingdom"], "Sector3": "Auto Loans"}, {"CountryList": ["France", "Germany", "Italy", "Netherlands", "Portugal", "Spain", "Sweden"], "Sector3": "Consumer Loans"}, {"CountryList": ["France", "Portugal", "United Kingdom"], "Sector3": "Mixed Auto Loans and Leases"}, {"CountryList": ["Germany", "Ireland", "Italy", "Spain"], "Sector3": "Consumer and Commercial Leases"}, {"Country |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
makeReactiveTrigger <- function() { | |
rv <- shiny::reactiveValues(a = 0) | |
list( | |
depend = function() { | |
rv$a | |
}, | |
trigger = function() { | |
rv$a <- shiny::isolate(rv$a + 1) | |
} | |
) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
library(shiny) | |
library(ggplot2) | |
makePlot <- function(xvar, yvar) { | |
ggplot(iris, aes_string(xvar, yvar)) + geom_point() | |
} | |
ui <- fluidPage( | |
selectInput("xvar", "X variable", choices = names(iris), selected = names(iris)[1]), | |
selectInput("yvar", "Y variable", choices = names(iris), selected = names(iris)[2]), |
OlderNewer