Training concepts: What is shaping?
What helps top trainers get excellent results?
They understand and use shaping.
If you’re new to dog training or clicker training, you might not be familiar with the word shaping. However, this is a really, really important training concept. The more you understand about shaping, the easier it will be for you to teach your dog new behaviors.
Shaping basically just means that you are going to use a series of steps to teach your dog to do a new behavior. By breaking the behavior into easily-achievable steps, your dog will feel successful during the training process. This will also speed up learning and reduce confusion and frustration! Most importantly, as your dog learns more and more new behaviors using shaping and positive reinforcement, he will start to enjoy learning new things and will look forward to interacting with you during training.Shaping speeds up training, reduces confusion, and makes learning fun. Click To Tweet
Here’s a simple example. Imagine you want to teach your dog to voluntarily go into his crate when you say “Go to your crate.” You could first reward the dog for approaching the crate and putting one foot in the crate. After working on this for a bit, you could then reward him for getting halfway into the crate. Later, you could wait for him to get all the way in the crate before giving him the reward. Finally, you could reward him when he gets all the way in the crate and then lies down. A trainer would say that the dog has been “shaped” to get into the crate.
Often with simple behaviors such as sit, the trainer expects the animal to do the whole movement from the beginning. However, it can be difficult or impossible to require the animal to do the whole behavior from the start for more complex behaviors or behaviors that involve a longer sequence of responses. Shaping gives the trainer a way to communicate complex tasks to the animal. It also increases understanding because the trainer breaks the behavior into small, achievable tasks that are taught one step at a time.Shaping increases understanding because behaviors are broken into small, achievable tasks. Click To Tweet
Great shaping is both science and art. Trainers who have shaped lots and lots of different behaviors are often able to train new behaviors quickly and with very minimal errors. They are able to set up the training so that the animal can be happy and successful at every step of the process.
In this post you’ll learn about the formal definition of shaping, questions to think about before you start shaping a new behavior, and why shaping sometimes doesn’t work. I’ve also included a dozen great examples of shaping in Part 2.
Psst… This post is pretty long! I encourage you to bookmark it so that you can refer back to it. I also encourage you to download the handout that I made to accompany this post.
PART 1: The definition of shaping
Shaping is commonly defined as:
The differential reinforcement of successive approximations toward a target behavior.
Now, that’s a mouthful!
In plain English, this basically means that you start by reinforcing (rewarding) little pieces of the behavior, and gradually build up the behavior until you reach your final goal.
However, let’s break this down and look specifically at each of the major elements in the definition of shaping. Understanding each of the three core elements will help you when training your dog and when designing your own shaping plans.
Target behavior. Your target behavior is your final goal. It’s what you want to achieve as a result of the training process. You’ll want to make sure you have a clearly defined target behavior before you start training. This means thinking through exactly what you want the dog to be doing, what situation(s) the dog will do the behavior in, what cues you’ll use, and any other particulars.
For example, perhaps you are worried about your dog running out the door when visitors come over. So, you decide you will teach him a really solid stay. However, saying “I want my dog to sit and stay and not run out the door” isn’t nearly precise enough! Exactly when and where do you want the dog to stay? In order to effectively solve this problem, you’ll want to be specific regarding when and how the dog should do the behavior.
So instead, your target behavior might be to have your dog go to his dog bed in the living room when the doorbell rings and then stay lying on his bed while you open the front door to collect a package or let a visitor into the house. See how this is much more precise than the goal in the previous paragraph?
Successive Approximations. The successive approximations are the baby steps you will use to train your target behavior. Rather than starting with the final behavior, you will start by rewarding approximations to the final behavior. Each step, or approximation, will take you closer to your goal.
For instance, did the previous example of teaching the dog to go to his bed when the doorbell rings seem impossible to you? This is a behavior that would be pretty difficult or even impossible for a lot of dogs! However, by breaking the behavior into a series of smaller, achievable steps, it becomes much easier to teach.
You could start by teaching your dog to voluntarily go to his bed. Then, you could teach him to do this when the doorbell rings. Next, you could teach him to stay on the bed for longer and longer amounts of time, while you move around the room. Then, you could have him stay on his bed while you open the door and finally, while you let a person come in. (Note: These are all still very BIG steps. Each of these steps would likely be broken down into a dozen or more smaller steps.)
Some people are skeptical about shaping. They think that it will take a lot of time to train a behavior, if they have to break the behavior down into lots of little steps. However, the reverse is usually true. Small steps actually make the training go faster because the communication is clearer and the animal understands exactly what to do.When used correctly, shaping leads to fast learning and really strong, reliable behaviors. Click To Tweet
Differential Reinforcement. The basic process that keeps shaping going is reinforcement. Every time the animal does the right behavior, the trainer follows this with something that the animal likes, such as a food treat, a belly rub, the chance to chase a ball, or anything else that the animal finds rewarding. The trainer knows that reinforcement is occurring if the animal continues doing the behavior and actually does the behavior more frequently.
The interesting thing about shaping is that there are always some behaviors being rewarded, and other behaviors that don’t earn rewards. This is the process that behavior scientists and psychologists call differential reinforcement.
Back to the example with the dog bed. If your dog has not been previously trained to go to his bed on cue, you might start by giving him a treat any time he puts a foot on the bed. Since you have his favorite treats and you start by standing right next to the bed, he figures this out fairly quickly. Pretty soon, he understands this step and is repeatedly offering to step onto the bed with his front feet. Every time he does this, you reinforce the behavior by giving him a treat.
So, you go on to your next step (your next approximation) and now only give him a treat if he puts all four feet on the bed. If he only steps on the bed with his front feet, he no longer gets a treat. Even though this behavior previously earned a treat, it doesn’t any more. Your pup starts experimenting a bit, and it doesn’t take long for him to catch on to the new requirement. Now he is going all the way onto the bed each time. Once he is doing this reliably, your next step might be for him to go all the way onto the bed and then lie down. For this step, standing on the bed would no longer earn a reward, but lying down would.
At each step, the approximation you are currently working on will earn reinforcement. If the dog offers behaviors from previous steps or completely unrelated behaviors, these won’t earn reinforcement. As a result, the behavior that is earning reinforcement increases in frequency, until the dog is spending most of his time engaged in this behavior. The other behaviors that aren’t earning reinforcement don’t happen as often or disappear entirely. This is the process of differential reinforcement.
(That said, trainers do sometimes go back and reinforce behaviors from previous steps, depending on the dog and on the behavior being trained. This can be useful sometimes if the dog is getting frustrated or confused with the current step.)
The trick with shaping is to divide the behavior into the right steps so that every time you move to the next step, it is very easy for the animal to figure out the new requirement. If the steps are too big, it will be too difficult for the animal to figure out what you want when you move to the next step. This can lead to frustration and confusion, because the animal will be attempting different behaviors, but not getting reinforced often enough.
Designing the right shaping steps is the topic for another blog post (or even a whole book….), but for now I want you to just remember that with a good shaping plan, it should be very easy for the dog to succeed and it should not be difficult for the dog to figure out what you want at each step. If the dog is offering a lot of extra behaviors or unwanted behaviors or can’t figure out what you want, you’ll need to add in some intermediate steps or even rethink your whole plan.With a good shaping plan, it should be very easy for your dog to figure out what you want! Click To Tweet
PART 2: Video examples of shaping behavior
That first part was a lot of words, wasn’t it? This next section includes some video examples of shaping so that you can see how it actually works. With a skilled trainer and an experienced dog, a new behavior can sometimes be shaped incredibly quickly.
However, if you are new to shaping, it can be difficult at first to determine how to teach a behavior and what behaviors you should and shouldn’t reinforce. Becoming a great shaper takes time and practice, well-developed observation skills, great timing, good planning skills, and being able to predict what the animal will do next.
One way you can learn more about shaping is by watching others. As you watch these videos, pay attention to what steps (“successive approximations”) the trainer uses to train the behavior. Does the trainer do certain things that make it easier for the animal to figure out the correct behavior? What behaviors does the trainer reinforce (and what behaviors does the trainer not reinforce) at each step?
Eight shaping examples with dogs
Shaping example 1: Ginger learns to lower her head
In this video, my mother’s dog, Ginger, learns how to lower her head using shaping. This was the second day we had worked on this behavior, so Ginger understood that the objective was to lower her head. You’ll see that she experiments with how far she needs to lower her head and that I wait for a little bit more behavior each time.
Shaping example 2: Dazzle learns to blow bubbles
This is just a silly trick, but it is a very nice example of shaping! Notice how the trainer (Kat of KatsDogs) gradually shapes the dog to lower her head farther into the bowl, and also to hold her head in the bowl for longer durations of time. All the while, she is gradually adding more water. Observe how at the beginning Kat is purposeful about reinforcing when the dog has a closed mouth, and not when the dog is licking the water. This video also has a nice example (around the one-minute mark) of how the placement of the food can be used to encourage the behavior in the correct direction.
Shaping example 3: Cross your paws
Here’s a fun video from Emily Larlham, aka kikopup. As you watch the progression of steps in this video, you’ll see how the trainer initially gets the paw movement and then uses a series of steps to gradually remove the object. This video also discusses how it can be helpful to momentarily go back to a previous step if the dog gets confused.
Shaping example 4: Puppy problems: Getting on your shoes
Most of the examples so far have involved tricks. However, shaping can be used to teach your dog just about any behavior! In this video, dog trainer Sarah Owings shows how a previously shaped behavior (relax on a mat) can be expanded to teach a puppy to sit quietly next to her while she puts on her shoes. This is a difficult behavior for a young pup! Notice how Sarah continues to reinforce often to help the puppy succeed and to let him know that he is doing the right thing. In future sessions, she would be able to gradually reduce the number of treats given.
Shaping example 5: Teaching a dog to go to a mat
This is a very interesting shaping example and perhaps one of my favorite YouTube videos. Watch closely the sequence of steps in this video from British trainer Kay Laurence. It is a rather unconventional way to teach “go to a mat,” but very effective. Rather than rewarding the dog for getting closer and closer to the mat, watch how the trainer (Helen) starts instead without using the mat at all.
Shaping example 6: Training a shoulder target to a dog
In this video by Donna Hill, the dog is learning to touch her shoulder to the trainer’s hand. Donna trains a lot of service dogs. This task teaches the dog body awareness and can later be used to teach more complex behaviors. Watch the different behaviors the dog offers. At the beginning, the dog offers some backing up. Through careful reinforcement, Donna is able to communicate the correct behavior to the dog.
Shaping example 7: Crawl under an object
Here’s another video from Emily Larlham. In this example of shaping, the dog is learning how to crawl under an object. The first dog in the video illustrates nicely how learning can happen very, very quickly when the dog has a lot of experience with shaping. Notice how Emily makes the behavior easy at first for Tug by using a tall object that he can go under easily.
Shaping example 8: Teaching a visual match to sample
With shaping, anything is possible! We’ll end with an example of a very smart pup. This video shows the progression of shaping steps that were used to teach a poodle named Chase to perform a matching task. Chase learns how to look at an object and then find the object on the table that matches the one that the trainer is holding. This video was the co-grand prize winner in the 2011 Canis Film Festival.
Four shaping examples with other animals
Of course, dogs aren’t the only ones that get to have all the fun! Here are four more shaping examples with some other types of critters. With positive reinforcement and shaping you can teach most any behavior to most any creature, as long as the animal is physically able to do the behavior.
Shaping example 1: Kindle the cat learns to ring a bell
Many people will falsely tell you that cats can’t be trained. This is certainly not true! However, it can take extra patience sometimes, depending on your cat. This video is a nice example of shaping, again from Kat of KatsDogs. Watch how the trainer starts by reinforcing any paw movements and then gradually focuses in so that the cat only receives reinforcement when she hits the top of the bell and makes it ring.
Shaping example 2: Stella the horse loads into the trailer
Stella the rescued bay quarter horse mare was initially very scared and unsure about getting into a horse trailer. A series of shaping steps was used to teach her to progressively go farther and farther into the trailer and then to stay in the trailer for longer periods of time. Most horse training today still involves ample use of force, coercion, and corrections. However, with shaping and positive reinforcement, a horse can learn to voluntarily go into a trailer. (Note: This video was edited to show the steps involved. We spent quite a bit of time on each step to build Stella’s confidence and to get her comfortable going into the trailer.)
Shaping example 3: Jackson the horse learns to enjoy having a halter put on
When my friend Maasa adopted Jackson, he was very skeptical about having a halter put on. He would even walk away if someone tried to approach him with a halter. Maasa didn’t just want to teach Jackson to stand still while she put on his halter. Instead, she wanted to teach him to actively participate in the process and to enjoy having his halter put on. This video is a bit longer, but it does a nice job of showing all of the shaping steps that were used to train this behavior.
Shaping example 4: Amy the rat learns the bucket trick
In this shaping example, you’ll see the series of steps that I used to teach Amy to raise a bucket to get a tasty treat. I start by teaching her to eat a treat from the bucket and then to pull up on the bucket. Next, over a series of steps, she gradually learns to pull the bucket longer distances. At one point, I make it too hard and have to go back to an easier step. Amy eventually learned to pull the bucket from quite a distance! Here is a short video clip of the final behavior.
PART 3: Four BIG questions to ask before you begin shaping a behavior
(Note: These four questions are not “mine.” They are paraphrased from and originate from the work of several behavior analysts, in particular, Dr. B.F. Skinner and Dr. Israel Goldiamond.)
Question 1: Where are you going? / What behavior do you want to train?
This might seem too basic, but this is the all important question. Where are you headed? What behavior are you wanting to train? Before you begin training, you should spend some time thinking about what you want the final behavior to look like. What will the animal be doing? How will the animal move and act? What should be the animal’s energy level and emotional state while doing the behavior? What cues will you use? In what settings will the animal do this behavior and what sorts of distractions might be present?
Consider these questions before you begin. I would even encourage you to jot down the answers on a piece of paper. It is really easy sometimes to think of an idea and want to run off to go start training before you’ve really fully thought through the idea. If you do not have a clear goal, you will often find that the behavior you end up training is not quite the one you originally imagined!
Question 2: Where are you now? / Where will you start?
Once you work out your goal, you’ll also want to spend some time thinking about where exactly you and your dog are now. A nice analogy for this relates to getting directions before you leave on a road trip. In order to get directions, you need precise information about both the location of your final destination and about your starting point.
It’s easy to get stuck thinking about this just from the negative perspective. Perhaps the next trick you want to train your dog to do is to bow, with his front legs and chin on the ground and his hind end sticking up in the air. Where are you now? Your first answer might be, “Well, my dog doesn’t know how to bow at all, so that’s where I’m at.”
Instead, consider “Where am I now” from a positive perspective. Sure, you dog doesn’t know how to bow, but he probably knows other behaviors. What behaviors does your dog already know that will help you when training this behavior? Can you start with one of these behaviors? Perhaps your dog knows how to stand in front of you and make eye contact. You might start with this and then gradually reinforce when your dog lowers his head or his shoulders, until he is bowing.
As you consider where to begin, remember that shaping will work best if you begin with a behavior that your dog already knows or that your dog will be able to do very easily. This will help the dog be successful at the very beginning. Now is the time to also consider if there are any pre-requisites that you might want to spend some time reviewing first, or if the dog is lacking certain pre-requisite skills, you might need to teach these first.
Question 3: How will you get there? / What will be the steps of your shaping plan?
Before you start training, you will want to have a well laid out plan of how you think you will train the behavior. You will want to consider how you will progress toward the final behavior, the different steps you will use, and how you will decide when to move on at each step.
While it’s important to have a solid plan, it’s also important to remember that you can change your plan! If something is not working, stop training. Try to figure out what is going on, and then, adjust your plan as needed. If you find that you are repeatedly getting stuck, take some video and review it yourself or have a friend review it.
Also, it’s important to remember that there is almost always more than one “right” way to train every behavior. Some ways you will want to avoid because they involve force, coercive training methods, corrections, or intimidation. However, don’t get stuck because someone tells you that there is only one right way to shape a certain behavior. If your shaping plan isn’t working, see if you can figure out a completely different way to approach it.
Question 4: What will keep it going / What will maintain the behavior?
When your dog chooses to do a behavior, he is motivated by one of two reasons – he acts to gain access to something he wants, or he acts to avoid or prevent something that he does not want to happen.
If this idea is new to you, think about your dog’s natural behavior throughout the day. He whines at you when he’s hungry and wants breakfast served, paws at the door to go outside to go potty or chase squirrels, walks a wide path around the big armchair when the cat is sitting on it, naps by the window so he can catch the afternoon sun, and brings you a ball when he’s ready to play.
Clicker trainers and positive reinforcement trainers stick to the positive motivators – they use things that the animal is eager to work for as motivation, rather than relying on corrections, coercion, physical force, or other unpleasant means of motivating behavior.
So, what will make your dog really want to do the behavior you are planning to train? Trainers often use food treats because most dogs like them. As well, the dog can consume a small treat quickly, and then get back to the next behavior. However, there are lots of other options – getting to play briefly with a tug toy or chase a ball, getting petted or scratched, and more. Really, you can use anything, as long as it gets your dog excited and he is willing to do behaviors in exchange for it.
You’ll want to consider the reinforcers (rewards) you will use during training and whether this will differ from the reinforcers you want to use to maintain the final version of the behavior once it is completely trained. For the final version of the behavior, your reinforcer might take a different form. For instance, imagine training your dog to sit and wait patiently while you open the back door. Initially, you might shape this behavior using treats. However, later on, you could use a more “natural” reward, such as getting to go outside and play or getting to go on a walk. Or, you might teach your dog to do a new trick and use playing with a tug toy as the reward while shaping the behavior. Later, you might incorporate this trick into a larger sequence of tricks, with one big reward at the end.
These are the four big questions that I would suggest you consider any time you are about to train a new behavior. However, for those who want more questions to consider, I’ve also put together a more comprehensive list of 21 questions to ask yourself before shaping a new behavior. You can download the handout by clicking on the image below.
PART 4: When shaping “fails” to work
Shaping is a very powerful training tool. However, it isn’t always easy. It takes time and practice to become good at shaping and, even then, things sometimes don’t go as planned. You are working with a living, breathing creature, after all!
When something doesn’t work, it can be easy to get frustrated and to want to give up. Instead, however, spend some time analyzing what happened and trying to figure out why things didn’t go as planned. This can often lead you to a new way to approach the problem.
Here are half a dozen reasons why shaping sometimes doesn’t work. If you’re having trouble shaping a behavior, consider if one of these reasons applies to your training.
1) The animal (or trainer) lacks certain essential pre-requisite skills.
Training plans often fail because the animal is missing necessary pre-requisite behaviors. If this is the case, the trainer has to figure out what behaviors are lacking and go back and teach these. For example, if your friendly dog does not already have a very solid stay, he will probably struggle if you try to teach him to stay sitting at your side when a stranger comes up to say “hi” to you. If the trainer is missing certain skills, this can also slow down or disrupt training.
2) The shaping steps are too big.
Trainers who are new to shaping often make the mistake of trying to ask for too much new behavior at each step. The trainer moves from Step 1 to Step 2, not realizing that Step 2 really should be Step 5 and that she is missing three additional intermediate steps. If the jumps between the steps are too large, the animal won’t be able to figure out what to do next, which can lead to confusion and then frustration.
3) The trainer doesn’t have an effective reinforcer.
For shaping and positive reinforcement training to work, you will need a reward that excites your dog and that your dog is willing to work for. You will lose your dog’s attention if there’s nothing worthwhile in it for him. Similarly, there are sometimes “competing reinforcers” in the environment — things that are just way more interesting to your dog, even though you have something that is normally a valuable reward. For example, you might have your dog’s favorite jerky treats, but suddenly two squirrels start chasing each other in the big tree right behind you. Training (and especially training new behaviors) becomes difficult if you don’t have a worthwhile reinforcer or when you have other things competing for your dog’s attention.
4) The trainer is shaping in the wrong direction.
Sometimes in shaping, everything seems like it is going along really well, but then everything seems to fall apart. What can happen is that the behavior “looks” correct initially, but the dog is actually learning the wrong behavior. For example, you think that you’ve shaped you dog to go sit on a carpet square that is positioned in front of you, but really he’s just learned to go sit several feet in front of you. Once you change positions, everything falls apart because he hasn’t realized that the carpet square is part of the behavior. Something similar can happen if the trainer uses prompts or lures incorrectly. The animal “appears” to be doing the correct action, but the animal has only learned to respond to the prompt or lure.
5) The shaping plan needs to be longer.
What about a dog that can do a perfect down stay in the living room, but can’t do it in the backyard or anywhere else with distractions? Or, perhaps a dog that can sit calmly when the owners come home, but can’t when visitors come to visit. This isn’t the fault of shaping. It just shows that the shaping plan didn’t have enough steps. The training plan needed to be extended, to teach the dog additional variations of the behavior or to teach the dog to do the behavior in additional places or settings. (In other words, the shaping plan needed to include more of what dog trainers call proofing and training for generalization.) The trainer should add additional steps and continue the training. You can largely avoid this issue if you think carefully from the beginning about all of the conditions where the dog will have to perform this behavior and then incorporate these relevant variables and conditions into your training plan.
6) The dog has physical limitations that make learning difficult or even painful.
Sometimes the shaping plan is good on the surface, but the dog can’t physically do what you are asking. In some cases, the dog might need additional physical conditioning to build muscles and flexibility, before he can advance through the shaping program. In other cases, the dog might have physical limitations that make the behavior very difficult or impossible. “Sit pretty,” whee the dog sits and the raises both paws up in the air, can be very difficult for some dogs, depending on the dog’s balance and the way the dog is built.
In traditional approaches to training, if the dog struggles to learn a behavior he is labeled as slow, unintelligent, or unmotivated. Some trainers might even tell you that the dog is stubborn or spiteful and is purposefully not learning.
However, a more useful approach is to consider instead that the dog just can’t understand what you are trying to teach. Usually, if you spend some time analyzing and revising your plan, you’ll be able to make some changes so that your dog can successfully learn the behavior you are trying to train. If you’re brand new to shaping or if you’re really stuck, I recommend finding a qualified professional trainer who can mentor you and help you and your dog learn more about shaping.
What behaviors will you train using shaping?
That was quite a lot of words! I’m impressed if you’ve stuck around this long. If you have, I’d love to know what behaviors you have taught using shaping and what behaviors you plan to teach next to your dog (or other critters).
Don’t be shy, leave a comment below!
Also, if you have a behavior you’re thinking about shaping, I encourage you to download the free handout that I created to accompany this post. It outlines 21 questions to ask yourself before you start training a new behavior.