| Date: | Fri, 17 Aug 2007 12:49:25 -0400 |
| Reply-To: | Kevin Roland Viel <kviel@EMORY.EDU> |
| Sender: | "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU> |
| From: | Kevin Roland Viel <kviel@EMORY.EDU> |
| Subject: | Re: Programming Logic |
| In-Reply-To: | <1187368768.764741.30100@z24g2000prh.googlegroups.com> |
| Content-Type: | TEXT/PLAIN; charset=US-ASCII |
|---|
On Fri, 17 Aug 2007, Reeza wrote:
> I'm trying to solve a problem whereby there are contractors who bill
> us for services, and we know how much service is billed and the total
> amount, but not the individual rate for each each service.
> Yes, it doesn't make sense, but its what I have to deal with.
>
> So the data is in a form as follows:
>
> data example;
> input x1 x2 z1;
> cards;
> 2 1 85
> 1 3 95
> ;
> run;
> Where for example we have two products x1 and x2 and two invoices,
> totalling 85 and 95 dollars respectively and I need to solve for the
> individual prices. I think I need to use IML here, any suggestions or
> help is much appreciated.
>
> This is a simplified problem. In real life I have about 30 unknowns
> and 50 contract equations.
Hmmm...without testing (or thinking very much because it is LUNCH time on
Friday)....
ods trace on ;
proc reg data = example ;
z1 = x1 x2 ;
run ;
quit ;
ods trace off ;
HTH,
Kevin
Kevin Viel, PhD
Post-doctoral fellow
Department of Genetics
Southwest Foundation for Biomedical Research
San Antonio, TX 78227
|