随笔分类 - 统计计算
摘要:Plot x <- c(1, 2, 3, 4, 5) y <- c(3, 7, 8, 9, 12) plot(x, y) 其他参数: type='l' main="My Graph" xlab="The x-axis" ylab="The y axis" col="red" cex=2, 点的大小,
阅读全文
摘要:title: "Lectures" author: '01' date: "2022-09-23" output: pdf_document knitr::opts_chunk$set(echo = TRUE) R-basics R变量的命名格式 必须以字母开头 只能包含字母、数字、下划线和.。 对
阅读全文
摘要:R变量的命名格式 必须以字母开头 只能包含字母、数字、下划线和.。 对大小写敏感 不能是保留关键字 数据类型(mode) numeric - (10.5, 55, 787) integer - (1L, 55L, 100L, where the letter "L" declares this as
阅读全文
摘要:两种方式: edit()自动生成一个红色的表格,列名会自动的放上去,不够的会显示var5,var6,var7 mydata <- data.frame( age = numeric(0), gender = character(0), weight = numeric(0) ) mydata <-
阅读全文
摘要:关于R基础 有3个需要总结的地方 R的画图(统计学图,ggplot) R的基本语法 R dataframe相关 Plot plot(1,2) plot(c(1, 2, 3, 4, 5), c(3, 7, 8, 9, 12)) x <- c(1, 2, 3, 4, 5) y <- c(3, 7, 8,
阅读全文
摘要:title: "Analysis of Variance" author: '01' date: "2022-11-23" output: html_document editor_options: markdown: wrap: 72 library(dplyr) library(ggplot2)
阅读全文
摘要:Levels are different groupings within the same independent variable(factor). Eg. if the independent variable is “eggs” the levels might be Non-Organic
阅读全文
摘要:统计计算就快要结课了!! 这学期一共涉及了一下知识点: Simulation 随机数生成 MC Hypothesis Testing (parametric)假设检验 Regression Analysis线性模型 Analysis of Variance Resampling Statistics
阅读全文
摘要:Bootstrapping Boostrap 有放回的重抽样。 符号定义: 重复抽样的bootstrap 观测到的样本 ,是一个经验分布 真实分布 Eg. 有一个要做估计的参数 用原始样本做估计的估计值 用重抽样样本做估计的估
阅读全文
摘要:library(dplyr) library(ggplot2) library(knitr) library(palmerpenguins) library(tidyr) Regression keys: response variable, predictor variable 做预测,并且给出该
阅读全文
摘要:Lecture_9-hypothesis_Testing_with_R library(tidyverse) library(knitr) library(dplyr) library(palmerpenguins) library(ggplot2) Statistical inference 通过
阅读全文
摘要:Monte Carlo Integration 找到原函数,再计算 无法找到原函数,MC积分 Assume that we can generate , and define $\hat \theta_n = \frac{1
阅读全文
摘要:library('ggplot2') library('dplyr') Lecture 6 Methods for generating random numbers Goal: Use U(0, 1) numbers to generate observations (variates) from
阅读全文