You know the stingray shuffle—where you shuffle your feet at the beach in order to avoid getting stung by a ray—but do you know what you should do when you encounter a shark?

As it turns out, it depends on their behavior.

“It’s important to preface this by saying that shark behavior is a very inexact science, there’s still a lot that we don’t know,” Patrick Rex, a graduate student who was presenting for the Cal State Long Beach Shark Lab, told California lifeguards on Friday.

Researchers told the lifeguards that if a shark is swimming in a steady direction at a steady pace near you, it’s likely just checking you out and is considered docile. However, if its swimming erratically or circling you, it might be defensive or “food-motivated.”

It’s important to note that while “food-motivated” might sound like a shark wants to eat you, we’re normally not on our toothy friends’ lunch menu.

In either case, its best to keep your eyes on the shark, the researchers said. In the latter cases, you should do that and back up slowly and steadily. If you’re holding any type of food, like a speared fish or bucket of chum, drop it and back off. But, be aware of your surroundings and make sure you’re not getting in between potential prey and the shark. And always report a shark sighting to the nearest lifeguard.

The Shark Lab recently received $3.75 million from the state of California to lead shark research and outreach that aims to improve beach safety.

Lifeguards from the Central Coast of California to the beaches of San Diego gathered for the first time since 2014 to hear the latest on sharks from Long Beach’s leading expert on the creature, Chris Lowe, the director of the Shark Lab.

Shark Lab representatives showed the room of first responders how to tell the difference between a Great White Shark and a Gray Whale calf and other sea mammals that are often mistaken for sharks by teaching them shark behavior when inactive, or docile, and when they are active and more threatening.

“The challenge is sharks are coming back, they’re on more and more of our beaches, more people are using water than ever before and the lifeguards are the ones dealing with the public on a day-to-day basis, so they need science-based information to make good decisions on how to better advise the public,” Lowe said.

With the extra state funds, the Shark Lab is able to expand its outreach efforts and help update statewide shark protocol.

“The more scientific research that’s added into our programs, the more understanding that we have of our ocean environment, the better our policies become,” said Brian Ketterer, a Coastal Division Chief for California State Parks.

While shark attacks are still relatively rare, sightings and incidents have been occurring more and more frequently in recent years, Lowe said. Especially in Long Beach, where mother sharks use the shallow water near shore as nurseries for their calves.

The funds also allow the lab to provide new educational materials. Along with putting additional monitoring equipment into the water, the lab is working with a graphic artist to create an comic book for kids that would teach them how to react in a situation with a shark.