Virtual Switches in ANY-maze
an Introduction to Virtual Switches - ANY-maze

Virtual Switches in ANY-maze

"Virtual Switches" is one of ANY-maze protocol items, a very useful tool. Let's learn something more about them!

What is a "Virtual Switch"?

No alt text provided for this image

As the name implies, a virtual switch is something which is either ON or OFF.?

Why "virtual"? Well, a virtual switch doesn't really exist; it's just something you create to determine when other things are in a state you want to consider as being on or off.


When to use a "Virtual Switch"?

No alt text provided for this image

A virtual switches is used to determine on/off type events based on other information ANY-maze already knows:

so for example, a virtual switch can be used to determine a "RUNNING" episode, that is when the animal is moving faster than a certain speed: when it is, the 'switch' will be on; when it isn't, the 'switch' will be off.

Virtual switches can also be used to determine the correlation between two or more on/off type events . For example, when two behaviours detected using keys are both occurring, or alternatively, when either of them occur.

As the example shows, a virtual switch can be used to threshold instantaneous values within ANY-maze, that is something which has a value at an instant in time, like the animal's speed.

Of course, you can set more than one virtual switches, even to define the same value, speed in our case. For example, you can set 3 switches for 3 different speed ranges:

  • Fast - Moving faster than 1.0 m/s
  • Medium - Moving between 0.3 m/s and 1.0 m/s
  • Slow - Moving slower than 0.3 m/s

There are a number of instantaneous values that can be thresholded using virtual switches

  • The speed of the animal
  • The distance of the animal from a zone (when outside the zone)
  • The distance of the animal from the border of a zone (when inside the zone)
  • The distance of the animal's head from a zone (when outside the zone)
  • The distance of the animal's head from the border of a zone (when inside the zone)
  • The distance of the animal from a point
  • The distance of the animal's head from a point
  • The relative length of the animal
  • The value reported by a signal
  • The value reported by a sensor
  • The speed of rotations of a rotary encoder
  • The value reported by a VALUE type plug-in.

ANY-maze, and we will gladly add more if requested

Grouping on/off values

Another way to turn a virtual switch on and off is to use other on/off items within ANY-maze. For example, you could specify that a switch should be on when either a photobeam is broken, or a key onthe keyboard is pressed.

Virtual switches and zones

Virtual switches are automatically analysed both for the apparatus as a whole and also within zones.

This means, for example, that a virtual switch which 'thresholds' the animal's speed would allow you to see how much time the animal spent moving 'fast' not just in the entire apparatus, but also in each zone individually.

No alt text provided for this image

Using virtual switches in procedures

Like many protocol elements in ANY-maze, you can use virtual switches in procedures. This means that a procedure can do such things as

No alt text provided for this image

  • turn on a sound if the animal is moving faster than a certain speed
  • start the video recorder whenever the animal is closer than a certain distance to a zone
  • or end the test if the combined sum of time 'on' of a number of keys is above a certain value.

How to set a "Virtual Switch"

No alt text provided for this image

To add a virtual switch to a protocol, click the + Add item button in the ribbon bar and select New virtual switch from the menu which appears, or right-click on the item "Virtual Switch", in he BEHAVIOR section of the protocol.


No alt text provided for this image

What you need to do then is follow the instruction

  1. Enter the virtual switch's name
  2. Specify what will cause the virtual switch to turn on
  3. If you set the switch to 'threshold' a measure, choose which measure it should be
  4. If you set the switch to 'threshold' a measure, specify the upper and lower threshold limits
  5. If you set the switch to group other on/off items, specify which items they should be.

No alt text provided for this image

Questions?

This was just a brief introduction to a powerful ANY-maze tool.

If the article triggered your curiosity, or if you have any questions, search "Virtual Switches in ANY-maze HELP section, or simply drop an email to [email protected] and we will be glad to provide additional information

要查看或添加评论,请登录

Stoelting Europe的更多文章

社区洞察

其他会员也浏览了