中文乱码的根源在于 windows 基于一些历史原因无法全面支持 utf-8 编码格式,并且也无法通过有效手段令其全面支持。
- 安装
# .png with Windows GDI versus .png with cairographics | |
doInstall <- TRUE # Change to FALSE if you don't want packages installed. | |
toInstall <- c("ggplot2", "RColorBrewer", "Cairo") | |
if(doInstall){install.packages(toInstall, repos = "http://cran.us.r-project.org")} | |
lapply(toInstall, library, character.only = TRUE) | |
# Generate some data | |
nn <- 100 | |
myData <- data.frame(X = rnorm(nn), |
#' Convert a list of vectors to a data frame. | |
#' | |
#' This function will convert a list of vectors to a data frame. This function | |
#' will handle three different types of lists of vectors. First, if all the elements | |
#' in the list are named vectors, the resulting data frame will have have a number | |
#' of columns equal to the number of unique names across all vectors. In cases | |
#' where some vectors do not have names in other vectors, those values will be | |
#' filled with \code{NA}. | |
#' | |
#' The second case is when all the vectors are of the same length. In this case, |
stat_smooth_func <- function(mapping = NULL, data = NULL, | |
geom = "smooth", position = "identity", | |
..., | |
method = "auto", | |
formula = y ~ x, | |
se = TRUE, | |
n = 80, | |
span = 0.75, | |
fullrange = FALSE, | |
level = 0.95, |
*.xls diff=xdoc2txt
This guide will enable systemd
to run as normal under WSL 2. This will enable services like microk8s
, docker
and many more to just work
during a WSL session. Note: this was tested on Windows 10 Build 2004, running Ubuntu 20.04 LTS in WSL 2.
To enable systemd
under WSL we require a tool called systemd-genie
Copy the contents of install-sg.sh
to a new file /tmp/install-sg.sh
: