Skip to content

Instantly share code, notes, and snippets.

Avatar
⚔️

S-Katagiri Gedevan-Aleksizde

⚔️
View GitHub Profile
@Gedevan-Aleksizde
Gedevan-Aleksizde / pop.pdf
Last active Oct 22, 2020
有限母集団のやつ
View pop.pdf
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View logistic.ipynb
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@Gedevan-Aleksizde
Gedevan-Aleksizde / Kalman.R
Last active Dec 9, 2019
Linear Kalman filter and animation
View Kalman.R
# multivariate normal Kalman filter
require(dplyr)
require(tidyr)
require(ggplot2)
require(animation)
# ARIMA(1,1) + 線形トレンド の乱数生成
N <- 50
phi1 <- .5
theta1 <- .2
View KFAS_crash.R
require(KFAS) # 1.2.9
require(dplyr)
require(tidyr)
require(ggplot2)
require(data.table)
require(zoo)
##### read dataset #####
# https://catalog.data.gov/dataset/allegheny-county-crash-data
# data description
View mountain_parameter.R
pacman::p_load_gh("uribo/fgdr", "franapoli/pbarETA")
pacman::p_load(sf, raster, tabularaster, tidyverse, broom, ggthemes, plotly, Metrics)
plot_surface <- function(mat) plot_ly(x=mat[, 1], y=colnames(mat), z=mat[, -1]) %>% add_surface()
options(pillar.sigfig = 10)
list_xml <- list.files("data", pattern="FG-GML-5133-36.+DEM5.+.xml", full.names=T)
pb <- txtProgressBar(min=2, max=length(list_xml), style=3, char="", width=getOption("width") - 30)
source <- list()
for(i in 1:length(list_xml)){
View bayesplot_tutorial.R
require(rstan)
require(bayesplot)
require(ggplot2)
require(ggthemes)
require(patchwork)
require(tidyverse)
rstan_options(auto_write = TRUE)
options(mc.cores = parallel::detectCores())
#### rstan でモデルをコンパイルしサンプリング ####
View bench.Rmd
---
title: "benchmark"
author: "ill-identified"
output:
pdf_document: default
html_document: default
---
## JIT 有効になってるとこれの結果が変わるかを検証
View CAR_20180813.R
require(tidyverse) # ver. 1.2.1
require(CARBayes) # ver. 5.0
require(sf) # ver. 0.6-3
require(ggplot2) # ver. 3.0.0
require(ggthemes) # ver. 4.0.0
require(ggmcmc) # ver. 1.1
rmse <- function(y, pred){
return(sqrt(mean((y - pred)^2)))
}
@Gedevan-Aleksizde
Gedevan-Aleksizde / heatmap.R
Created Jul 22, 2018
気象庁からダウンロードした気温データでヒートマップ作成する
View heatmap.R
require(tidyverse)
require(ggthemes)
require(rjson)
require(jsonlite)
# 参考
# https://www.data.jma.go.jp/gmd/risk/obsdl/index.php
# https://www.data.jma.go.jp/gmd/risk/obsdl/top/help3.html#hukajoho
# https://twitter.com/mehori/status/1020644999703089152
View pull_data.py
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
"""
Created on Sat Mar 31 22:57:58 2018
https://www.quora.com/How-can-I-extract-only-text-data-from-HTML-pages
https://qiita.com/matsu0228/items/edf7dbba9b0b0246ef8f
@author: ks
"""
import sys, re, datetime