Skip to content

Instantly share code, notes, and snippets.

@heiwais25
heiwais25 / next-auth-naver.ts
Last active October 6, 2020 09:58
Next-Auth with Naver
{
id: 'naver',
name: 'Naver',
type: 'oauth',
version: '2.0',
params: { grant_type: 'authorization_code' },
profileUrl: 'https://openapi.naver.com/v1/nid/me',
profile: (profile) => {
return {
id: profile.response.id,
@heiwais25
heiwais25 / package.json
Created October 24, 2019 14:53
Basic Setup json to run create react app with redux
{
"name": "name",
"version": "0.1.0",
"private": true,
"dependencies": {
"@types/jest": "24.0.19",
"@types/node": "12.11.6",
"@types/react": "16.9.9",
"@types/react-dom": "16.9.2",
"immer": "^4.0.2",
pnorm(0, 0, 1) = 0.5 # Cumulative distribution function of 0
qnorm(.25, 0, 1) = -0.675 # .25 quantile
hists(rnorm(10000, 0, 1)) # histogram of values from rnorm(10000 pseudo random sample)
dnorm(0, 0, 1) = 0.3989423 # PDF value at 0
x = seq(from = -5, to = 5, by = .1) # make x points to draw distribution
plot(x, dnorm(x, 0, 1), type="l") # connect points by line in the plot
dnorm(0, 0, 1) = 0.3989423 # PDF value at 0
x = seq(from = -5, to = 5, by = .1) # make x points to draw distribution
plot(x, dnorm(x, 0, 1), type="l") # connect points by line in the plot
1. P(x=2) : dpois(2,2) = 0.271
2. P(X>2) : 1 - ppois(2,2) = 0.323
3. P(X<2) : ppois(2,2) = 0.677
4. P(0.5<X<2) : pgamma(2,2,1/2) - pgamma(0.5,2,1/2) = 0.238
5. P(X<z) = 0.8 : qnorm(.8, 0, 1) = 0.842
6. P(-1.96 < X < 1.96) : pnorm(1.96, 0, 1) - pnorm(-1.96, 0, 1) = 0.950
7. P(-z < X < z) = 0.98 : qnorm(0.99, 0, 1) = 2.32 # Due to its symmetry