Join Paul F. Aubin for an in-depth discussion in this video Adding a calculated value, part of Revit: Tips, Tricks, and Troubleshooting.
- [Voiceover] In this movie we're going to look at calculated values in a schedule. A calculated value is a special field that you can add to a schedule that actually performs a calculation on other fields within the schedule. Now, while it's not likely to replace Excel anytime soon, it certainly can give you some valuable insights into basic data that's contained within your model. So let's look at a really simple scenario here. Let's imagine that I have some room that I need to lay out and I've gotten the required minimum areas for those rooms from my client.
So, perhaps, we went to a meeting and they gave me a list and they said I'm gonna need this many offices and these are the square footage's that will be required in each of those offices. So I've got a room schedule and two things to point out here, there's a required area column and an area column. In the area column you'll notice that most of the rooms say "not placed" and then the required area column does have some values input in there. So, let's click on the field here and the first thing I wanna do is select the required area and click this edit button.
Required area is actually a custom parameter that I added to the project so, I just simply called it "required area", I made the type of parameter and area, and if I hide the unchecked categories here you can see that I applied it to rooms, so it's a really simple parameter that I'm able to then fill in whatever the required square footage is for this particular room. Now, the area column is the built-in area column for the rooms and when a room hasn't been placed in the model yet it shows up as "not placed", but how exactly do you get one of these non-placed rooms? Well, you do it directly here in the schedule using the "insert data row" button right here.
So, if I click "insert data row" it will create another room I can give it a number and I can give it a name, and I can give it a required area. So assuming that I had that meeting with the client and I got all this information I can pre-populate my schedule with all of those values. Now the next thing that I wanna do is create a calculated value that compares the required area with the actual area and alerts me whether or not I'm in compliance so I'm gonna go back to "fields" and click on "calculated value".
I need to give this a name so I'm just gonna call this "check" cause it's gonna check the area. It's gonna be a formula and its going to return a text value. So this is the part that's a little tricky. Even though it's a formula and it's gonna run numeric calculations, what kind of information do I want it to return? And what's the result gonna be? And the reason it's gonna be text is my formula's gonna look like this: I'm gonna use an "if" statement. Now, an "if" statement allows you to just ask a question that has basically a true and false answer and so if the answer ends up true, you do one thing and if the answer ends up false, you do something else.
So I'm gonna write "if" (open parentheses) and then over here I can click the small little "browse" button and it will show me all of the fields that are currently in my schedule. So, I'm gonna say "if the required area is less than the area" and then I put a comma. So, if the required area is less than the area so if the answer to that is "true" that yes the required area is less than the actual area, then the value, if true, is going to be "okay".
Now I'm putting it in quotes because this is a text field. If I just write "okay", Rev it will think that I have a parameter called "okay". Then you put a comma and you put the value if false and there I'll just put an "x" or you could write "non compliant" or you can write whatever you want there and close the parentheses. So the way to read this is like a sentence. You say, "if the required area is less than the area, then list "okay" otherwise list an x". So that's basically the way that that sentence reads.
Now I'm gonna click "okay" and then "okay" again and so I'll get my "check" column over here. Now I'm gonna test to make sure that I got it right. My "corridor" is already inserted in the model so I'm gonna click in the "required area" column for the "corridor" and type in a value. So, if I type in a value of 500 as my "required area" and I press "enter", it will say that that's okay because I only required 500 square feet, but you gave me 513 so we're good, but if I put in a "required area" of 600 square feet then it's gonna put "x".
That's not okay, you need to add more. If I put in exactly 513 it'll still say it's okay because the required area is not less than the area so it's still okay. On the other hand, if you had 514 then it would list as "x" so this tests out the formula, we can see that it's correct and let's just go ahead and put in 500 there to complete that out. So now we're gonna add the rest of these so let me minimize this down here and kinda put this over here so we can see it as we're working and then let's go ahead and add these other rooms.
So how do you add these non-placed rooms into a model? Well, you go to your "room" command and before you click anywhere notice on the "options" bar that the "room" drop-down says "new" okay so if I were to click I'd be placing a brand new room. What you wanna do is open this list instead and all of your non-placed rooms will be listed there. So here's "101 office" and I'll put that one right here. Notice that it comes in and it says "the required area is 300-you only gave me 266" so that one's not okay.
And then I'm gonna keep going. Here's 102, here's 103, here's 104 and here's 105. So all of the rest of them are okay. So it's only that first office that is not okay and then I can go and make whatever modifications to my model to get that room into compliance. Now let's look at another example. Another interesting thing that we can do if we go back to the schedule is I'm gonna add another calculated value to this schedule here.
So I'm gonna go to "fields" and click "calculated value" again and I'm gonna call this one I'm gonna call this one "percentage of total". There's a "percentage" option here and the way that this works is you're taking the percentage of one of your numerical fields, so in this case I'm gonna take the percentage of my "area" field, my actual area not my required area and then you're dividing that by and in this case I'm gonna divide that by the "grand total" Now it would let me divide it by the number, but that would be kinda silly cause that's room number so that really wouldn't yield a very good result.
So the "grand total" is what I wanna do here and this is gonna be a really simple calculation that it's gonna do, but now it's gonna actually tell me what percentage of the total each rooms area represents in the total project so that value might be useful for you when you're performing your analysis and doing your design and trying to meet certain requirements based on your client. So these are two really simple examples of calculated values that you can do in your schedule. Once again, it's not gonna replace Excel.
For more detailed calculations you can still export a schedule out to a text file and then open that in Excel and run additional calculations, but to do some of these really simple calculations right here in the Rev it model it's very convenient to have all of that information right at your fingertips.
NOTE: The exercise files for this course can only be opened in the most recent version of Revit (Revit 2017).
Skill Level Appropriate for all
Q: Why can't I earn a Certificate of Completion for this course?
A: We publish a new tutorial or tutorials for this course on a regular basis. We are unable to offer a Certificate of Completion because it is an ever-evolving course that is not designed to be completed. Check back often for new movies.