由买买提看人间百态

boards

本页内容为未名空间相应帖子的节选和存档,一周内的贴子最多显示50字,超过一周显示500字 访问原贴
Mathematics版 - a hash embedded with another hash in R (转载)
相关主题
Re: Another simple question!Second order linear ODE with mixed boundary condition
another help for limit那什的那个等距嵌入是不是有个几页纸的证明?..
[合集] 还我一片安宁 -- 洪家兴 [ZT bbsland.com]ZZ:北大78级数学,张益唐 (里面有莫宗坚的八卦)by Tang Tao
问一个微分方程组的问题.5岁儿童学围棋中表现的数感(多图)
ask for help...waiting on line.....Cauchy-Schwartz的本质是什么?
请教: 工程专业背景的读一个part-time数学Master困难吗?帮忙看看这个题
a question about basic group theorygraph embedding into manifold?
help MATLAB:KNITRO third-party libraries陈省身评价纳什
相关话题的讨论汇总
话题: hash话题: first话题: list1话题: h1话题: embedded
进入Mathematics版参与讨论
1 (共1页)
l******9
发帖数: 579
1
【 以下文字转载自 Statistics 讨论区 】
发信人: light009 (light009), 信区: Statistics
标 题: a hash embedded with another hash in R
发信站: BBS 未名空间站 (Fri Apr 11 15:56:40 2014, 美东)
This question is related to my previous question.
I need to design a hash that is embedded with another hash in R in Rstudio
on Win 7.
library(hash)
myf <- function()
{
h1 <- hash()
if (!has.key("first", h1))
{
list1 <- list()
h1.son<- hash()
h1.son["first_son"] <- list1
h1["first"] <- h1.son
}
# second check
if(!has.key("first_son", h1["first"]))
{
list1 <- list()
h1.son<- hash()
h1.son["first_son"] <- list1
h1["first"] <- h1.son
}
}
myf()
Why in "second check ", h1["first"] still has NO key of "first_son", which
has been added before.
Thanks !
1 (共1页)
进入Mathematics版参与讨论
相关主题
陈省身评价纳什ask for help...waiting on line.....
Puzzle 1.请教: 工程专业背景的读一个part-time数学Master困难吗?
请问有什么HASH算法可以用来检索一组数字的?a question about basic group theory
a probability problemhelp MATLAB:KNITRO third-party libraries
Re: Another simple question!Second order linear ODE with mixed boundary condition
another help for limit那什的那个等距嵌入是不是有个几页纸的证明?..
[合集] 还我一片安宁 -- 洪家兴 [ZT bbsland.com]ZZ:北大78级数学,张益唐 (里面有莫宗坚的八卦)by Tang Tao
问一个微分方程组的问题.5岁儿童学围棋中表现的数感(多图)
相关话题的讨论汇总
话题: hash话题: first话题: list1话题: h1话题: embedded