Borrar filtros
Borrar filtros

How to design preferential behavior analysis with matlab

6 visualizaciones (últimos 30 días)
Miguel
Miguel el 4 de Nov. de 2022
Respondida: Ayush Anand el 31 de Ag. de 2023
Hello,
Ive been learning matlab to help in a research position I was recently hired in. Right now, I'm trying to figure out how I could do a preferential behavior analysis.
This study is light/dark preferential behavior, and my idea to solve this was to overlay a grid on my image(s) of choice, with a "boundary" meaning "light side" or "dark side" and from there, make counts depending on where my subject is over a period of time and place that into a table for easy tabulating.
Was hoping if someone could point me to some documentation/the right direction (So I can learn how to do it myself:) )as my current google-fu hasn't been too fruitful. If it's any help, I'm using MARGO so my image/subject tracking is all set using their framework via centroids of subject of interest, I'm just not sure how I could go about implementing the grid idea for preferential behavior/if this is the right way of approaching this.

Respuestas (1)

Ayush Anand
Ayush Anand el 31 de Ag. de 2023
Hi Miguel,
I understand you want to implement preferential behavior analysis in MATLAB to study light/dark preferential behavior. You can use image processing and analysis techniques in combination with the MARGO framework for subject tracking. Here's a general approach you can follow:
  1. Image Preprocessing: Before analyzing the preferential behavior, you may need to preprocess your images to enhance the contrast between the light and dark regions. This can involve techniques such as image thresholding, filtering, or adaptive histogram equalization to improve the visibility of the regions of interest.
  2. Grid Overlay: Once you have preprocessed the images, you can overlay a grid on them to define the boundaries between the light and dark sides. You can use functions like "imoverlay" or "rectangle" to draw grids or boundaries on images. You can specify the grid size and position based on your experimental setup.
  3. Subject Tracking: Utilize the MARGO framework or any other tracking algorithm to track the subject of interest in each frame. Extract the centroid coordinates of the subject over time.
  4. Determine Side Preference: For each frame, determine whether the subject is located in the light or dark side based on its centroid coordinates and the defined grid boundaries. You can use the "inpolygon" function to check if a point is inside a polygon defined by the grid boundaries.
  5. Counting and Tabulating: Keep track of the side preference for each frame and accumulate the counts over time. You can store this information in a table or any suitable data structure for further analysis or visualization.
  6. Statistical Analysis: Once you have obtained the counts, you can perform statistical analysis to assess the preferential behavior. MATLAB provides a wide range of statistical functions and tools for this purpose, such as hypothesis testing, plotting, and summarizing the data.
You can refer the following MathWorks documentation on image processing toolbox to gain more insights and examples on how to use the same for various purposes:
I hope this helps!

Productos


Versión

R2022b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by