similar to: count appearence of zero in a vector

Displaying 20 results from an estimated 2000 matches similar to: "count appearence of zero in a vector"

2012 Sep 24
4
serial subtraction within a vector
Hello, I have a vector (numeric) v-> c(a,b,c,d,e) and I want to create the vector n->c(b-a,c-b,d-c,e-d). How can I do that? Thank you Hermann [[alternative HTML version deleted]]
2012 Sep 05
2
Installing lumi and hdrcde
To whom it may concern. As I would like to analyse some array data I was keen on downloading the lumi package that depends obviously on hdrcde that is not available for r 2.12.1. I did not find instructions to solve or circumvent this problem. Installing hdrcde by hand did not work either. It was not detected by > (.packages(all.available=TRUE)) if installed in the R library. Thanks Hermann
2012 Sep 15
2
qplot: plotting precipitation data
Dear list, I wish to plot chromatin precipitation data: I would like to have a rectangles (x:end-start, y:peak) but I do not have an idea how to define x (in terms of qplot syntax) and to choose the correct geom. mydata is a subset of a larger file. > mydata chrom start end peak 1 chr11 5291000 5291926 8 2 chr11 10988025 10988526 7 3 chr11 11767950 11768676 8 4
2013 Mar 29
3
From a vector with characters to binary information
Hello, I would like to transform a character vector into a "binary" vector ("keine" and " " become 0 and the rest 1). > dput (scm) c("keine", " ", "keine", "Erstgradverw.", "Mutter", "Erstgradverw.", "Erstgradverw.", "keine", " ", "Vater",
2012 Sep 10
3
plot: x and y chromosomes are missing
Hello, I have a list with gene names, fold changes (=expression level) and chromosomes. Names fold change chromosome hz 1.5 2 If I plot fold change versus chromosome (or vice versa): plot (ch, fc) I see only the chromosomes with numbers but not those with letter (x and y). What can I do? A second question: How can I add a single line in that plot at a certain
2013 Nov 08
2
making chains from pairs
Hello, having a data frame like test with pairs of characters I would like to create chains. For instance from the pairs A/B and B/I you get the vector A B I. It is like jumping from one pair to the next related pair. So for my example test you should get: A B F G H I C F I K D L M N O P > test V1 V2 1 A B 2 A F 3 A G 4 A H 5 B F 6 B I 7 C F 8 C I 9 C K 10 D L
2012 Nov 05
2
fusion of overlapping intervals
Hello, I have start and end coordinates from different experiments (DNase hypersensitivity data) and now I would like to combine overlapping intervals. For instance (see my test data below) (2) 30-52 and (3) 49-101 are combined to 30-101. But 49-101 and 70-103 would not be combined because they are on different chromosomes (chr a and chr b). Does anybody have an idea? Thanks Hermann > df
2012 Nov 01
2
subset a defined row plus the aforegoing
Hello, my data is sorted by start.ens (see below). And now I would like to extract all rows (so called* defined row*s) with type==Expression - subset (df, type==Expression) - and the aforegoing type==DNase HS (which is not necessarly row n-1 - assumung that the defined row is n). I dont know how to add this to my subset command. Is that possible? Thanks Hermann > df start.ens fc.trans
2017 Oct 30
3
run r script in r-fiddle
>>>>> Suzen, Mehmet <msuzen at gmail.com> >>>>> on Mon, 30 Oct 2017 11:16:30 +0100 writes: > Hi Frank, You could upload your R source file to a public > URL, for example to github and read via RCurl, as source > do not support https as far as I know. well... but your knowledge is severely (:-) outdated. Why did you not try first?
2017 Oct 30
0
run r script in r-fiddle
We were talking about r-fiddle. It gives error there [*], that's why I suggested using RCurl. > source("https://raw.githubusercontent.com/msuzen/isingLenzMC/master/R/isingUtils.R") ... unsupported URL scheme Error : cannot open the connection > On 30 October 2017 at 15:51, Martin Maechler <maechler at stat.math.ethz.ch> wrote: >>>>>> Suzen, Mehmet
2017 Oct 31
0
run r script in r-fiddle
On 31 October 2017 at 12:42, Martin Maechler <maechler at stat.math.ethz.ch> wrote: > Notably as I think it's been provided by a company that no > longer exists under that name, and even if that'd be wrong, R-Fiddle > does not seem free software (apart from the R parts, I hope !). For the record, r-fiddle is maintained by datacamp:
2013 Oct 03
1
prcomp - surprising structure
Hello, I did a pca with over 200000 snps for 340 observations (ids). If I plot the eigenvectors (called rotation in prcomp) 2,3 and 4 (e.g. plot (rotation[,2]) I see a strange "column" in my data (see attachment). I suggest it is an artefact (but of what?). Suggestion: I used prcomp this way: prcomp (mat), where mat is a matrix with the column means already substracted followed by a
2013 Jan 09
5
R encrypt/decrypt
Hello, I am working on a web system (php) that uses R in the backend, and we need some basic fast encryption/decryption for the underlying mysql database that can be used by both R AND php. It does not need to be top-of-the-line, but just provide some basic level of fast encryption/decryption. Any suggestions? Thank you, Ramiro [[alternative HTML version deleted]]
2017 Sep 02
4
Block comment?
AFAIK block comment is not possible it needs to be implemented in R interpreter and defined in the parser.'If' solution is not elegant. On 2 September 2017 at 14:09, Uwe Ligges <ligges at statistik.tu-dortmund.de> wrote: > > > On 02.09.2017 11:40, Christian wrote: >> >> I consider it quite worth while to introduce into R syntax a nestable >> block comment
2017 Oct 31
1
run r script in r-fiddle
Dear List, According to datacamp support team, r-fiddle.org is not supported. We asked them to put it down as Professor Maechler suggested it is a waste of time for the R-help to respond to questions on something not maintained and severely outdated. If you would like to use R from your browser, you can embed the following into a web page: <script
2012 Jul 17
1
problem with function
Dear list, I have a problem with defining a function (see below) to read my testfile (see testfile). My function only returns mydata I wish to work with attr(mydata, 'fc') as well (for labelling a plot). Principally it works if I do not insist on this function but it would be much easer if it is possible to return mydata AND attr(mydata, 'fc') by using a function. 1) testfile:
2011 Sep 27
3
read.csv behaviour
This might be obvious but I was wondering if anyone knows quick and easy way of writing out a CSV file with varying row lengths, ideally an initial data read from a CSV file which has the same format. See example below. I found it quite strange that R cannot write it in one go, so one must append blocks or post-process the file, is this true? (even Ruby can do it!!) Otherwise it puts
2011 Sep 27
3
read.csv behaviour
This might be obvious but I was wondering if anyone knows quick and easy way of writing out a CSV file with varying row lengths, ideally an initial data read from a CSV file which has the same format. See example below. I found it quite strange that R cannot write it in one go, so one must append blocks or post-process the file, is this true? (even Ruby can do it!!) Otherwise it puts
2017 Oct 30
3
run r script in r-fiddle
Hi All, I want to know how to run an R file on my computer in R-Fiddle? I tried source("filename.r"), but not working. thanks, Frank [[alternative HTML version deleted]]
2017 Oct 31
2
run r script in r-fiddle
>>>>> Suzen, Mehmet <msuzen at gmail.com> >>>>> on Mon, 30 Oct 2017 16:05:18 +0100 writes: > We were talking about r-fiddle. It gives error there [*], > that's why I suggested using RCurl. >> source("https://raw.githubusercontent.com/msuzen/isingLenzMC/master/R/isingUtils.R") > ... unsupported URL scheme Error