search for: method2

Displaying 20 results from an estimated 36 matches for "method2".

Did you mean: method
2008 Mar 02
2
[LLVMdev] Struct layout assumptions
...s could do a better job if I preserve the type info. OK, so we come to the issue of inheritance: Suppose I have a class A and subclass B, each of which have two methods. One way to layout the vtable for B is to include the vtable for A as a sub-structure, i.e.: A.vtable = { A.method1 *, A.method2 * } B.vtable = { { A.method1 *, A.method2 * }, B.method1 *, B.method2 * } The advantage of this form is that when you upcast B to an A, the pointer to the B vtable can be upcast as well - i.e. its a valid pointer to a B vtable is also a valid pointer to an A vtable. However, when it comes t...
2010 Jan 04
3
how to draw abline correctly?
...e it. I wrote the following code, but there are 3 problems 1, the red line is added on the graph but without any marker on the y-axis. I want to display the number '.1361' on the y-axis. So people can easily tell 'method 2' gets a constant estimate, which is 0.1361. 2, since 'method2' is a constant. I prefer in the legend area, it just shows 'method2' as a short red bar instead of a knot/spot in the middle of the red bar in the legend area. How can I delete that spot? 3, when I draw 'method1' in blue one, I prefer a filled/shaded circle instead of the unsh...
2006 Jun 22
1
Change of controller name and SEO issue
Hi, I developed an app with cetain controller names. Now that the app is catching up I''m trying to change the controller names to be better aligned with the business. This is what I have now. http://localhost/foo/method1 http://localhost/foo/method2 http://localhost/foo/method2/a http://localhost/foo/method2/a/b http://localhost/foo/method2/a/b/c http://localhost/foo/method3 I would like to have that changed to http://localhost/bar/method1 http://localhost/bar/method2 http://localhost/bar/method2/a http://localhost/bar/method2/a/b http://lo...
2006 Jul 06
3
Calling Method
Is there a way to call a method if I only have a string that contains the method name. For example: @methods = [''method1'', ''method2'', ''method3''] @step = 1 # I want to call method2 which has a definition in this class -- Posted via http://www.ruby-forum.com/.
2005 Sep 25
1
Prototype "classes" and inheritance
...lize''] = function() { _super_initialize.apply(this, arguments); _derived_initialize.apply(this, arguments); } delete destination._super_initialize; } return destination; } testObject_extend_with_super: function() { with(this) { var superInitArgs, method1Args, method2Args; var Super = Class.create(); Super.prototype = { initialize: function() { superInitArgs = arguments; }, method1: function() { method1Args = arguments; }, method2: function() { method2Args = arguments; } }; var Derived =...
2010 Aug 20
2
U value from wilcox.test
...3 others by the method 2. So I have 2 groups of 3 samples, that are not paired. I would like to know if the results obtained by these 2 methods are significantly different, I hope method 2 to be more efficient than method 1. As I have few data I went for the Mann-whitney test: method1=c(35,40,56) method2=c(90,110,115) wilcox.test(method1,method2,paired=FALSE,alternative="less") Wilcoxon rank sum test data: method1 and method2 W = 0, p-value = 0.05 alternative hypothesis: true location shift is less than 0 As I have a small number of samples, I would prefer to compare the U value o...
2001 Apr 25
6
Updated partial auth patch against CVS
Here is a new version of my partial auth patch against the April 24, 2001 CVS image. It fixes a couple of things (thanks to Karl M <karlm30 at hotmail.com>), and includes support for hostbased auth. It's still not pretty, but it works. 2 things Karl mentioned aren't fixed: - auth methods are still hard-coded into servconf.c. Fixing this would require a lot of work, and all the
2008 Nov 23
1
tklistbox - R-Objekt
...hat purpose looks like that: require(tcltk) tt<-tktoplevel() tl<-tklistbox(tt,height=4,selectmode="single",background="white") tkgrid(tklabel(tt,text="select method for LAI calculation")) tkgrid(tl) method<- c("method1","method2") for (i in (1:2)){ tkinsert(tl,"end",method[i]) } tkselection.set(tl,0) OnOK <- function(){ choice<-method[as.numeric(tkcurselection(tl))+1] tkdestroy(tt) } OK.but <-tkbutton(tt,text=" OK ",command=On...
2003 Aug 05
1
code speed help? -- example and results provided
....x2..i... 0 0 0 0 0 0 1 1 1 1 append.x1..i....x2..i... 0 0 0 0 0 0 1 1 1 1 append.x1..i....x2..i... 0 0 0 0 1 1 1 1 1 1 append.x1..i....x2..i... 0 0 0 0 0 1 1 1 1 1 > > > > ###1000 samples#### > samples<-1000 > w.life<-round(rnorm(samples,5,.5),digits=0) > system.time(method2<-replacement2.idx()) [1] 12.79 0.00 14.04 0.00 0.00 > > > > ###5000 samples#### > samples<-5000 > w.life<-round(rnorm(samples,5,.5),digits=0) > system.time(method2<-replacement2.idx()) [1] 544.82 0.00 593.98 0.00 0.00 >
2007 Dec 08
3
Multiple Worker Methods on Different Schedules
...dule different worker methods defined in the same worker to trigger at different times, is this possible? Would the following scheduler yaml work? :schedules: :foo_worker: :worker_method: method1 :trigger_args: 0 */10 * * * * * :job_key: some_key_1 :foo_worker: :worker_method: method2 :trigger_args: 0 */15 * * * * * :job_key: some_key_2 Would this work? Is there some other way to do it? Would the second method need to be pulled into a separate worker? Thanks, Andy -------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pi...
2007 Nov 13
5
how to ensure signature compliance while mocking in ruby
On 13/11/2007, Pradeep Gatram <pradeep.gatram at gmail.com> wrote: > > Let me put my dilemma as an example. Take a look at a snippet from > FooTest. > > #using mocha > def test_method1 > Bar.expects(:method2).with(''param1'', ''param2'').once > Foo.method1 > end > > And now the implementation > > class Foo > def self.method1 > Bar.method2(''param1'', ''param2'') > end > end > > class Bar > e...
2011 Feb 24
1
accuracy of measurements
Dear R people Could you please help with following Trying to compare accuracy of tumor size evaluation by different methods. So data looks like id true metod1 method2 ... 1 2 2 2.5 2 1.5 2 2 3 2 2 2 etc. Could you please give a hint how to deal with that. Seems like {merror} does not suite to me because I am trying to compare accuracy of measurements with their true known values not just overall agreement of methods. Moreover sample size is ridiculously sm...
2011 Aug 16
2
how to get the result in "short cut" manner?
Hi all: My data:data(sleep) If I wanna calculate each group's extra,what I can do is: #method1 attach(sleep) mean(extra[group==1]) mean(extra[group==1]) #method2 result<-matrix(,0,2) g<-split(sleep,sleep$group) for(i in 1:length(g)) { result<-rbind(result,data.frame(unique(g[[i]]$group),mean(g[[i]]$extra))) } colnames(result)<-c("name","mean") But the above 2 method is a little bit tedious.Is there a "short cut" ma...
2006 Jan 26
3
global objects?
Forgive the term global if that''s not applicable in rails (i come from a php background) I have a browse controller with a couple of different methods def method1 @properties = Property.find_all #other stuff for that method end def method2 @properties = Property.find_all #other stuff for that method end def method3 @properties = Property.find_all #other stuff for that method end I know RoR is all about not repeating yourself if you don''t have to. Is there a way to say @properties = Property.find_all 1 time and have it be...
2011 Jun 01
1
Function to save plots
Hello, I'm using ROCR to plot ROC Curves and I want to automate the saving of plots into PNG files using a custom function. My data frames are named like test1, test2, test3. Each data frame has three variables: method1, method2, goldstandard. Right now, for each plot I have to run: png('test1_method1.png') plot(performance(prediction(test1$method1, test1$goldstandard), "tpr", "fpr")) dev.off() Here is the function I tried to create but I failed: roc <- function(arg1, arg2){ png(paste(a...
2006 Apr 22
3
Creating a select dropdown box with links to methods
...def select_view # Depending on the selection, redirect to a certain view. if params[:selection] = ''choice1'' redirect_to(:action => ''method1'') elsif params[:selection] = ''choice2'' redirect_to(:action => ''method2'') else redirect_to(:action => ''method3'') end end I''m sure there is a better way to do this but I can''t find it. Plus, even though they are quite trivial I''m sure my if/elsif statement is messed up somewhere as it works, bu...
2006 Aug 11
1
Excluding all the methods of a class from a filter.
Hello, I would like to be able to exclude all the methods of a specific class from being subject to methods called by before_filter entries. Right now I have all those methods excluded using :except => [methode1,method2,...] but there must be a better way. Thanks in advance, Alexandre. -- Posted via http://www.ruby-forum.com/.
2012 Sep 04
0
get only little part of html with htmlParse
...ding="gbk") library(XML) xmltext2 <- htmlParse("http://www.jb51.net/article/27174.htm" ) 3.readLines options(encoding="gbk") library(XML) txt=readLines("http://www.jb51.net/article/27174.htm") xmltext3 <- htmlParse(txt,asText=TRUE) method1,and method2 are ok,they can get right content to be parsed. when i run method 3 ,to my surprise ,xmltext3 can get some contents,but many are gone,they are not the same as method1,and method2,why? you can get only little part of html. > xmltext3 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Tra...
2009 Nov 06
2
mini_magick - 2 clarifications
1. I have seen examples similar to the following: image = MiniMagick::Image.from_file("input.jpg") image.resize "100x100" image.write("output.jpg") I''m assuming that image.resize is a method. Is there any significance to the fact that the argument for that method is not enclosed in parenthesis while the other are? Examples seem to be consistent --
2007 Aug 31
48
Deprecating the mocking framework?
I saw in one of Dave C.''s comments to a ticket that "our current plan is to deprecate the mocking framework." I hadn''t heard anything about that, but then again I haven''t paid super close attention to the list. Are we planning on dumping the mock framework in favor of using Mocha (or any other framework one might want to plug in?). Pat