Learning SAS? Welcome to the exclusive online community for all SAS learners.

Help with functions?

Reply
Occasional Contributor
Posts: 19

Help with functions?

Can anyone please explain me the difference between sum(var1-varn) and sum(of var1-varn)?

Contributor
Posts: 45

Re: Help with functions?

VAR1 = 90

VAR2 = 40

SUM(VAR1-VAR2) gives 50

SUM(OF VAR1-VAR2) gives 130

If we don't use 'OF'  the symbol '-' will be treated as Minus.

Correct me if I am wrong.

Occasional Contributor
Posts: 19

Re: Help with functions?

Thanks! this is very helpful to me.

Ask a Question
Discussion stats
  • 2 replies
  • 319 views
  • 3 likes
  • 2 in conversation