## Cumulative Joint Bivariate Normal Probability Distribution with a given rho

I want to calculate the cumulative bivariate normal distribution of two standard normal variables.  Is  there a SAS PROC or SAS FUNCTION that does this?  When rho=0, this is easy but rho =^ 0, it's more involved.  For example, suppose x1=-2.05 and x2=-1.64. -2.05 is associated 0.02 with and -1.64 is associated with 0.05.  When rho=0, you just multiply 0.02*0.05 to get 0.001 but when rho N=^ 0 it's a little messy.  Trying to avoid writing the code if SAS has a PROC of FUNCTION that does this for me.  No IML please.

1 ACCEPTED SOLUTION

Accepted Solutions

## Re: Cumulative Joint Bivariate Normal Probability Distribution with a given rho

Yes, use the PROBBNRM function, which is in Base SAS. I describe the function and how to use it in the article "Visualize the bivariate normal cumulative distribution."

``````data CDF2D;
input rho x1 x2;
cdf = probbnrm(x1,x2,rho);
datalines;
0    -2.05 -1.64
0.5  -2.05 -1.64
-0.5 -2.05 -1.64
;

proc print data=CDF2D; run;
``````
6 REPLIES 6

## Re: Cumulative Joint Bivariate Normal Probability Distribution with a given rho

No IML? Trying to avoid writing the code? There is the PROBBNRM function in SAS, but that's not a cumulative distribution. And from that point on, I think you either need to write your own code, or use IML.

Update: this answer is incorrect; see comment from @FreelanceReinh below

--
Paige Miller

## Re: Cumulative Joint Bivariate Normal Probability Distribution with a given rho

@PaigeMiller wrote:

There is the PROBBNRM function in SAS, but that's not a cumulative distribution.

Hi @PaigeMiller, I think it is cumulative and hence ideal for PaulN's task.

(Thanks to Rick_SAS for mentioning the function recently enough so that I remembered it.)

## Re: Cumulative Joint Bivariate Normal Probability Distribution with a given rho

@FreelanceReinh thanks for the correction!!!

--
Paige Miller  Ksharp
Super User

## Re: Cumulative Joint Bivariate Normal Probability Distribution with a given rho

Better calling @Rick_SAS

## Re: Cumulative Joint Bivariate Normal Probability Distribution with a given rho

Yes, use the PROBBNRM function, which is in Base SAS. I describe the function and how to use it in the article "Visualize the bivariate normal cumulative distribution."

``````data CDF2D;
input rho x1 x2;
cdf = probbnrm(x1,x2,rho);
datalines;
0    -2.05 -1.64
0.5  -2.05 -1.64
-0.5 -2.05 -1.64
;

proc print data=CDF2D; run;
``````

## Re: Cumulative Joint Bivariate Normal Probability Distribution with a given rho

Thank you for the help.  It's appreciated.

Discussion stats
• 6 replies
• 406 views
• 5 likes
• 5 in conversation