加载中…
  
博文
标签:

rstudio

png

pdf

导出

分类: SAS_STATA_GAMS_MATLAB_Hadoop
png(filename='C:\\Users\\\\ANA\\Indem_2.6_2020.png',bg='transparent')
plot(yield_2.6_2020_dens,main = 'Expected Indemnity for 2020 (RCP 2.6)')
dev.off()

一直报错:
> dev.off
function (which = dev.cur()) 
{
    if (which == 1) 
        stop('cannot shut down device 1 (the null device)')
    .External(C_devoff, as.integer(which))
    dev.cur()
}
一直无法导出图片。

把dev.off 改成:
garbage <- dev.off()
就可以了。


标签:

stata

r

.dta

打开

5-12.dtafile

分类: SAS_STATA_GAMS_MATLAB_Hadoop
library(foreign)
data1 <- read.dta('C:\\Users\\jacky\\Dropbox\\research\\crop insurance paper\\demand\\data\\CORN_8913original_test.dta')

如果出现报错:
Error in read.dta('C:\\Users\\jacky\\Dropbox\\research\\crop insurance paper\\demand\\DATA MANIPULATION\\cpi.dta') :
  not a Stata version 5-12 .dta file

意味着这个dataset是stata13生成的,foreign这个library无法读取stata12以后的版本生成的.dta.解决办法是用readstata13这个library。

安装readstata13,然后:


library(readstata13)
CPI <- read.dta13('C:\\Users\\jacky\\Dropbox\\research\\crop insurance paper\\demand\\DATA MANIPULATION\\cpi.dta')
标签:

latex

高亮

highlight

landscape

分类: 其他软件及电子产品
highlight, 高亮:
\usepackage{soul,color}

 three \hl{of sorghum yields}
双倍行距:
  \usepackage{
标签:

标题

caption

对齐

indent

加粗

分类: 其他软件及电子产品
 \captionsetup{singlelinecheck=false}
%左对齐

\captionsetup[table]{justification=RaggedRight,labelfont=bf,textfont=bf,skip=10pt}
\captionsetup[figure]{justification=RaggedRight,labelfont=bf,textfont=bf,skip=10pt}
%加粗

标签:

latex

inputenc

error

分类: 其他软件及电子产品
Package inputenc Error: Keyboard character used is undefined(inputenc) in inputencoding `latin1'. ...' annual yields, planted acreage and RMAâ€

从word里粘过来一段文字,在TeXstudio里能compile,但每次都出现这样的报错,very annoying。 原因其实挺简单,原来word里有单引号,把单引号删了,在latex里面重新type就可以了。估计是word里面的单引号和latex里面不一样。
标签:

latex

图表

位置

中间

制定

分类: 其他软件及电子产品
Specifier Permission
h Place the float here, i.e., approximately at the same point it occurs in the source text (however, not exactly at the spot)
标签:

latex

字体

字号

大小

宽度

分类: 其他软件及电子产品
\begin{table}
\footnotesize
\begin{tabular}{p{4cm}p{8cm}l}
\hline 
\textbf{Variables} & \textbf{Definition} & \textbf{Notation in this study}\tabularnewline
\hline 
Dependent variable & normalized liabilities per acre/projected price & liab\_cpi\_acre\_price\tabularnewline
Price & normalized net premium per acre/projected price & netprem\_cpi\_acre\_price\tabularnewline
Expected yield & average yield in the preceding three years & mean\_lag\_yd3\tabularnewline
expected revenue & average revenue in the preceding three years & mean\_lag\_rev\_cpi3\tabularnewline
CV of yield & coefficient of variance for corn yield (1989-2013) & cv\_yield\tabularnewline
CV of revenue & coefficient of variance for revenue (1989-2013) & cv\_rev\tabularnewline
标签:

latex

excel

表格

table

分类: 其他软件及电子产品

http://s6/bmiddle/002dDHI1gy71FbahGTz95&690

在LYX 里选incert--table,调整所需要的行数和列数(如上图所示), 粘贴表格,粘贴之后常常所有的内容都被粘在一个表格里,这时候选择edit里面的paste special--plain text,内容就会被调整到各个cell里面。

http://s5/mw690/002dDHI1gy71FbtSs0A14&690

 

然后对表格进行调整,

 

view source,或者打开source pane 就可以看到对应的code,把这段code粘贴到要插入图表的地方再进行调整即可。



标签:

latex

texstudio

tutorial

教程

分类: 其他软件及电子产品
TeXstudio 只是Latex的编译器,所以安装TeXstudio后还要安装Latex才可以。
最简单的:
\documentclass[a4paper,12pt]{article} 
\begin{document} 
This is for fun!

\end{document}

在TeXstudio里面F1就可以看到生成的pdf

如果把documentclas 里的article换成book的话,正文会自动换到第二页开始



\documentclass{article}
(2015-11-26 01:54)
标签:

r

.nc

netcdf

分类: SAS_STATA_GAMS_MATLAB_Hadoop

How to Read Data in netCDF Format with R

Overview: 

R  is a software package for statistical computing and graphics. Data in netCDF forma

  

新浪BLOG意见反馈留言板 欢迎批评指正

新浪简介 | About Sina | 广告服务 | 联系我们 | 招聘信息 | 网站律师 | SINA English | 产品答疑

新浪公司 版权所有