我想用R覆盖同一设备上的2个密度图.我该怎么做?我搜索了网络,但我没有找到任何明显的解决方案(我对R来说很新).
我的想法是从文本文件(列)中读取数据然后使用
plot(density(MyData$Column1))
plot(density(MyData$Column2), add=T)
Run Code Online (Sandbox Code Playgroud)
这种精神......
提前致谢
我是Javascript的新手,我遇到了一个始终返回NULL的document.getElementById()的问题,这让我疯了.
我的代码中有一个元素,我想得到它的坐标,所以我可以移动它.
这是代码:
<html>
<head>
<script type="text/javascript" >
function MoveIt(obj) {
alert(obj); // returns "Object HTMLDivElement"
var xx = document.getElementById("arect");
if(document.getElementById("arect").value == null) {
alert('NULL >> ' + xx.value);
}
else {
alert('NOT NULL >>' + xx.value);
}
posX = xx.style.scrollTop;
posY = xx.style.left;
}
</script>
</head>
<body bgcolor="white" >
<DIV class="background" id="MyDiv2">
<div id="arect" name="arect" class="transbox" onmousedown="MoveIt(this);" >
</div>
</div>
</body>
</html>
Run Code Online (Sandbox Code Playgroud)
上面的函数MoveIt()总是返回NULL
我想编译一些第三方软件,但显然我遇到了ZLIB的问题.
见下文:
$sudo make
gcc -Wall -pedantic -DVERSION=1.2 -lz -O3 sliding.o trim_single.o trim_paired.o sickle.o -o sickle
trim_paired.o: In function `ks_getuntil':
trim_paired.c:(.text+0x78): undefined reference to `gzread'
trim_paired.o: In function `kseq_read':
trim_paired.c:(.text+0x48d): undefined reference to `gzread'
trim_paired.c:(.text+0x4dc): undefined reference to `gzread'
trim_paired.c:(.text+0x60a): undefined reference to `gzread'
trim_paired.c:(.text+0x687): undefined reference to `gzread'
trim_paired.o: In function `paired_main':
trim_paired.c:(.text+0xc62): undefined reference to `gzopen'
trim_paired.c:(.text+0xc83): undefined reference to `gzopen'
trim_paired.c:(.text+0x1142): undefined reference to `gzclose'
trim_paired.c:(.text+0x114f): undefined reference to `gzclose'
trim_single.o: In function `ks_getuntil':
trim_single.c:(.text+0x78): undefined reference …Run Code Online (Sandbox Code Playgroud) 有没有一种明显的方法在C++中执行货币格式化?
例如:1978879将成为1'978'879
谢谢
我在DIV中有一个巨大的SVG文件.我想通过单击A链接在div中滚动SVG.
我的问题是我希望我的DIV保持小于我的SVG文档,所以我可以有活动的滚动条.假设我的SVG文档的高度为10.000和1.100宽度,在200px x 100px DIV元素内.但无论我做什么,我的DIV元素都会像SVG一样大.我怎样才能抑制div的大小?
这是我的代码:
<html>
<title>
YOP
</title>
<head>
<style TYPE="text/css">
<!--
div.header{
background:black;
background-color: #ededed;
margin-top: 0px;
position: fixed;
top: 0px;
//width:100%;
width:1100px;
height: 500px;
}
-->
</style>
<script type="text/javascript" >
var pos = 0;
function MyFtion(){
var elem = document.getElementById('aSVG');
pos = pos + 100;
elem.scrollTop = pos + 100;
window.scroll(0, pos);
}
</script>
</head>
<body bgcolor="white" >
<div class="header" id="MyDiv2">
<a href='javascript:MyFtion()'>** Move s**</a>
</div>
<div id="oo" height="200px" width="100px" style="margin-top:100px;overflow:scroll;" >
<object id="aSVG" data="out.svg" style="margin-top:100px;overflow:hidden;" …Run Code Online (Sandbox Code Playgroud) html ×2
c++ ×1
currency ×1
density-plot ×1
formatting ×1
javascript ×1
plot ×1
r ×1
scrollbar ×1
svg ×1
zlib ×1