找回密码
 注册
查看: 367|回复: 0

R语言 solaR包 C_local2Solar()函数中文帮助文档(中英文对照)

[复制链接]
发表于 2012-9-30 11:47:31 | 显示全部楼层 |阅读模式
C_local2Solar(solaR)
C_local2Solar()所属R语言包:solaR

                                         Local time, mean solar time and UTC time zone.
                                         本地时间,平均太阳时与UTC时区。

                                         译者:生物统计家园网 机器人LoveR

描述----------Description----------

The function local2Solar converts the time zone of a POSIXct object to the mean solar time and set its time zone to UTC as a synonym of mean solar time. It includes two corrections: the difference of longitudes between the location and the time zone, and the daylight saving time.
函数local2Solar一个POSIXct对象的平均太阳时间和设置时区为UTC的代名词平均太阳时的时区转换。它包括两个更正:经度之间的位置和时区,夏令时的差异。

The function CBIND combines several objects (zoo, data.frame or matrix) preserving the index of the first of them or asigning a new one with the index argument.
结合的功能CBIND几个对象(zoo,data.frame或matrix)的保护index的第一个或一个签名,一个新的index参数。

The function lonHH calculates the longitude (radians) of a time zone.
功能lonHH计算经度(弧度)的时区。


用法----------Usage----------


local2Solar(x, lon = NULL)
CBIND(..., index=NULL)
lonHH(tz)



参数----------Arguments----------

参数:x
a POSIXct object
POSIXct对象


参数:lon
A numeric value of the longitude (degrees) of the location. If lon=NULL (default), this value is assumed to be equal to the longitude of the time zone of x, so only the daylight saving time correction (if needed) is included.
位置的经度(度)的数值。如果lon=NULL(默认值),这个值被假定为等于x,所以才有了夏令时修正(如果需要的话)中包含的时区的经度。


参数:...
A set of zoo objects.
一组zoo对象。


参数:index
A POSIXct object, the index of zoo object constructed with CBIND.
APOSIXct对象,zoo对象的索引构建CBIND。


参数:tz
A character, a time zone.
一个字符,一个时区。


Details

详细信息----------Details----------

Since the result of local2Solar is the mean solar time, the Equation of Time correction is not calculated with this function. The fSolI function includes this correction if desired.
由于local2Solar是平均太阳时的时间校正公式不计算使用此功能。如果需要的话,fSolI功能包含此修正。

If the index argument of CBIND is NULL (default) the first object of ... must be a zoo object.
如果indexCBIND参数NULL...必须是zoo对象(默认)的第一个对象。


值----------Value----------

The function local2Solar produces a POSIXct object with its time zone set to UTC.
函数local2Solar生产POSIXct对象的时区设置为UTC。

The function CBIND produces a zoo object.
函数CBIND生产zoo对象。

The function lonHH gives a numeric value.
函数lonHH给出了一个数值。


注意----------Note----------

It is important to note that the solaR package sets the system time zone to UTC with Sys.setenv(TZ='UTC'). Every zoo object created by the package will have an index with this time zone and will be supposed to be mean solar time.
重要的是要注意,solaR包设置系统时区UTC与Sys.setenv(TZ='UTC')。每zoo软件包所创建的对象将有一个索引,这个时区,并将于应该是平均太阳时。


(作者)----------Author(s)----------


Oscar Perpi帽谩n Lamigueiro.



参考文献----------References----------


实例----------Examples----------


t.local<-as.POSIXct("2006-01-08 10:07:52", tz='Europe/Madrid')

##The local time zone and the location have the same longitude (15 degrees)[#本地时区的位置具有相同的经度(15度)]
local2Solar(t.local)
##But Madrid is at lon=-3[#但皇马是在离子= -3]
local2Solar(t.local, lon=-3)

##Daylight saving time[#夏令时]
t.local.dst<-as.POSIXct("2006-07-08 10:07:52", tz='Europe/Madrid')

local2Solar(t.local.dst)
local2Solar(t.local.dst, lon=-3)

## Not run: [#不运行:]
##Extracted from an example of calcG0[#提取物的一个例子calcG0]
##NREL-MIDC[#NREL MIDC]
##La Ola, Lanai[#拉奥拉,拉奈]
##Latitude: 20.76685o North[#纬度:20.76685o北]
##Longitude: 156.92291o West[#经度:156.92291o西]
##Time Zone: -10.0[时区:-10.0]

file='http://www.nrel.gov/midc/apps/plot.pl?site=LANAI&amp;start=20090722&amp;edy=19&amp;emo=11&amp;eyr=2010&amp;zenloc=19&amp;year=2010&amp;month=11&amp;day=1&amp;endyear=2010&amp;endmonth=11&amp;endday=19&amp;time=1&amp;inst=3&amp;inst=4&amp;inst=5&amp;inst=10&amp;type=data&amp;first=3&amp;math=0&amp;second=-1&amp;value=0.0&amp;global=-1&amp;direct=-1&amp;diffuse=-1&amp;user=0&amp;axis=1'

dat <- read.table(file, header=TRUE, sep=',')
names(dat) <- c('date', 'hour', 'G0', 'B', 'D0', 'Ta')

##B is direct normal. We need direct horizontal.[#B是直接正常。我们需要直接的水平。]
dat$B0 <- dat$G0-dat$D0

##http://www.nrel.gov/midc/la_ola_lanai/instruments.html:[#http://www.nrel.gov/midc/la_ola_lanai/instruments.html:]
##The datalogger program runs using Greenwich Mean Time (GMT),[#数据采集器程序运行时使用格林威治标准时间(GMT),]
##data is converted to Hawaiin Standard Time (HST) after data collection[#数据被转换为数据收集后Hawaiin标准时间(HST)的]
idxLocal <- with(dat, as.POSIXct(paste(date, hour), format='%m/%d/%Y %H:%M', tz='HST'))
head(idxLocal)
idx <- local2Solar(idxLocal, lon=-156.9339)
head(idx)

## End(Not run)[#(不执行)]

转载请注明:出自 生物统计家园网(http://www.biostatistic.net)。


注:
注1:为了方便大家学习,本文档为生物统计家园网机器人LoveR翻译而成,仅供个人R语言学习参考使用,生物统计家园保留版权。
注2:由于是机器人自动翻译,难免有不准确之处,使用时仔细对照中、英文内容进行反复理解,可以帮助R语言的学习。
注3:如遇到不准确之处,请在本贴的后面进行回帖,我们会逐渐进行修订。
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

手机版|小黑屋|生物统计家园 网站价格

GMT+8, 2025-6-9 02:56 , Processed in 0.021694 second(s), 16 queries .

Powered by Discuz! X3.5

© 2001-2024 Discuz! Team.

快速回复 返回顶部 返回列表