search for: qti

Displaying 20 results from an estimated 125 matches for "qti".

Did you mean: _ti
2006 Jul 13
8
can''t convert true into integer
I have a method: ? def reduceProuctInventoryBy(product_id, reduction) ? ? t=Product.find(:first, :conditions =>["id = ?", product_id]) ? ? t.qty=(t.qty-reduction) ? ? t.save ? end and the model: class Product < ActiveRecord::Base ? validates_presence_of :qty, :specialDescription ? validates_numericality_of :qty end but when i run my method, I get this: "can''t
2011 May 27
1
Unable to Plot using headers.
Hello List! Thank you for your input so far. I have successfully imported my data into R but have hit a snag in plotting. Simple plot commands are unable to find my headers when I try and plot my data on an x/y scatter. My data is a 2 column 8000 row table (saved as .txt file) imported into R. >demand=read.delim("C:\\Documents and Settings\\E066582\\My
2012 Dec 03
1
qr.qy and qr.qty give an error message when y is integer and LAPACK=TRUE
With this example set.seed(123) A <- matrix(runif(40), nrow = 8) y <- 1:nrow(A) A.laqr <- qr(A, LAPACK=TRUE) both qr.qy(A.laqr,y) and qr.qty(A.laqr,y) give the respective error messages Error in qr.qy(A.laqr, y) : 'b' must be a numeric matrix Error in qr.qty(A.laqr, y) : 'b' must be a numeric matrix However when Lapack is not used as in A.liqr <- qr(A,
2007 May 15
2
QR Decompositon and qr.qty
Dear R people, I do not have much knowledge about linear algebra but currently I need to understand what the function qr.qty is actually doing. The documentation states that it calculates t(Q) %*% y via a previously performed QR matrix decomposition. In order to do that, I tried following basic example: m<-matrix(c(1,0,0,0,1,0,0,0,1,0,0,1),ncol=3) # 4x3 matrix
2001 Mar 22
1
lazy evaluation and DUP=F
I am having some difficulty understanding the implication of lazy evaluation mixed with DUP=F in a .Fortran call. In qr.qty from base DUP is not used as an argument so defaults to T. I am calling qr.qty with a very large array and would like to set DUP=F in the .Fortran call so that qr.qty would be defined as copied below. Is there some risk that a variable used as the argument in the original
2009 May 27
4
Sale, pop and product
Hi, I couldn''t find a better word for pop, but let''s go: There are 3 models: sale, pop and product sale: -total:integer pop: -quantity:integer -discount:float product: -name:string -price:float A sale can have many different products, each one has a quantity and discount associated. So each sale has_many :products through => pops And each product has_many :sales
2004 Jan 30
0
Two apparent bugs in aov(y~ *** -1 + Error(***)), with suggested (PR#6510)
I think there are two bugs in aov() that shows up when the right hand side of `formula' contains both `-1' and an Error() term, e.g., aov(y ~ a + b - 1 + Error(c), ...). Without `-1' or `Error()' there is no problem. I've included and example, and the source of aov() with suggested fixes below. The first bug (labeled BUG 1 below) creates an extra, empty stratum inside
2011 May 27
1
FW: FW: Unable to Plot using headers (converting to Numeric)
I tried command as.numeric(Qty) #converting column"Qty" in object "demand" to numeric. However it remains a non-numeric value. What is the best way to convert a column of data to a numeric value in R? What is the best way to convert dates into a numeric format (or some format able to be used in an x,y scatter) while still maintaining its inherent "date" property?
2004 Feb 02
0
Two apparent bugs in aov(y~ *** -1 + Error(***)), with (PR#6520)
I believe you are right, but can you please explain why anyone would want to fit this model? It differs only in the coding from aov(y ~ a + b + Error(c), data=test.df) and merely lumps together the top two strata. There is a much simpler fix: in the line if(intercept) nmstrata <- c("(Intercept)", nmstrata) remove the condition (and drop the empty stratum later if you
2002 May 30
0
se.contrast: matrix contrast.obj doesn't work as documented (PR#1613)
The man page for se.contrast, when describing the contrast.obj parameter, states that "Multiple contrasts should be specified by a matrix as returned by contrasts." When doing an unbalanced single factor ANOVA, using a contrast.obj as returned by contrasts results in the following error from qr.qty when se.contrast is called: Error in qr.qty(object$qr, contrast) : qr and y must have
2006 Apr 07
3
RJS removing content of div, but not div itself
Hi, I''m creating a list of ingredients on a page. When the user clicks the ''Add Ingredient'' button a record gets added to the db and the ingredient gets added to the page. On the page, each record is represented by a <div> with three <span>s inside. One of the <span>s has a link_to_remote to ''delete'' the ingredient. When the link
2011 May 27
1
FW: Unable to Plot using headers.
-----Original Message----- From: Struckmeier, Nathanael Sent: Friday, May 27, 2011 1:39 PM To: 'stephen's mailinglist account' Subject: RE: [R] Unable to Plot using headers. Thanks for the input. Despite both graphing directly and with "attach" I am still getting a screwed up graphical output as well as an error. My table is object "demand" w/ columns Date and
2006 Jan 10
1
Can somebody explain when to reload an ActiveRecord
Hi all, I''ve the following test method in my controller_test which increment the ''qty'' attribute in a has_many association, ''sa_report_products''. The ''item_count'' method returns the sum of all qty''s in ''sa_report_products'': def test_add_product_to_report sa_rpt = SaReport.find(1) assert_equal 3,
2012 Aug 20
1
function case in sqldf (datas from oracle) with a null value
I use sqldf to join 2 dataframes from 2 distinct databases : a and b come from old sqldf's. sqldf("select a.*, b.*, case a.QTY when null then b.QTY else a.QTY end as NEW_QTY" from a inner join b on a.OBJECT=b.OBJECT") R doesn't understand "when null". I tried with "when NA", "when '' ", "when ' ' " but it doesn't
2006 Apr 20
5
strange mysql problem
i have this model: class LineItem < ActiveRecord::Base belongs_to :quote end in the console: >>l = LineItem.create ActiveRecord::StatementInvalid: Mysql::Error: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' , , , )'' at line 1: INSERT INTO line_items (`qty`, `quote_id`,
2010 Jun 23
2
Analyzing large transition matrix
Let's say you have a dataframe of car trade-ins. For example, each row contains oldcar newcar qty and a typical entry could be lexus bmw 1 I put the qty column to allow for fleet purchases, where one purchase may convert multiple cars at once. I'd like to show what's going on. I could do a histogram of newcar to show the frequency each type of car is bought. If there
2005 Dec 20
1
nls problem
Hi list, I tried to use nls to do some nonlinear least square fitting on my data with 340 observations and 10 variables, but as I called nls() function, I got this error message: Error in qr.qty(QR, resid) : 'qr' and 'y' must have the same number of rows Then I traced back a little bit into nls() function, the error seemed to happen when calling nlsiter() internal function, but
2004 Mar 01
0
se.contrast ....too hard??? .... Too easy????? .....too trivial???? ...... Too boring.....too????????
Hi all, Regular and avid readers of this column will know that Don Driscoll and I have recently posted two messages requesting assistance concerning an apparent failure of "se.contrast" to produce an se for a contrast. So far, an ominous silence rings in our ears, but read on Gentle Reader, and see if even the machinations of "debug" doesn't stimulate you to respond with a
2011 Apr 18
1
how to update data
hi, I have json string in json request. i want to update the database using that string. how can i do that? There would be a multipal object in this string. sample string is:
2005 Dec 14
9
Passing quantity in a shopping cart
I am using this line on my index.rhtml page to capture the quantity required of a particular item for a basic shopping cart app: <%= text_field ''line_item'', ''quantity'', {:size=>3} %> </td> but my next screen (a cart screen) doesn''t reflect what was entered in that text field when the item is added to the cart. That is,