This forum uses cookies
This forum makes use of cookies to store your login information if you are registered, and your last visit if you are not. Cookies are small text documents stored on your computer; the cookies set by this forum can only be used on this website and pose no security risk. Cookies on this forum also track the specific topics you have read and when you last read them. Please confirm whether you accept or reject these cookies being set.

A cookie will be stored in your browser regardless of choice to prevent you being asked this question again. You will be able to change your cookie settings at any time using the link in the footer.

Fixed graph size and position instead of aspect ratio
I am not entirely sure if I understood the question correctly, because phyphox has both, options for axis ranges and aspect ratios, but they apply to different things. The aspect ratio has nothing to do with the scaling of the data but with what area on the screen is used by the graph. It is the ratio of the width of the image to the height of the image, no matter if it is showing valus from 0 to 1 or from -42 to 23. (This option is far from perfect and we are thinking of adding options to auto-fill the screen in the future.)

I think what you are looking for are the options minY, maxY, scaleMinY and scaleMaxY. The latter two can be set to "auto", "extend" and "fixed". "auto" and "extend" both rescale the graph to fit all data and for the audio scope, it is specifically set to "extend", which only "zooms out", but never zooms back in if the new data set has smaller values. What you want to do is scaleMinY="fixed" and scaleMaxY="fixed". If these are set, you can set minY and maxY to numbers which determine the range of the y axis.

However, there is one problem, which is why we did not elect to use a fixed range here. All the phones have different mics, amplifier circuits and maybe even different ways to filter the sound in software. The audio data is represented by samples between -1 and +1, but the exact scaling can vary a lot. So, if you set a fixed range that shows the audio of a normal voice nice on one phone, it could be too small or too large on another. For example, a loud noise shows up on my Nexus 5X at an amplitude of about 0.8, but on an iPhone 6s it only has an amplitude of 0.1.

Unless you are adapting this experiment for a specific phone to measure a specific sound, you should consider to add an edit box to enter a scaling factor. Or maybe, you will be more happy with the upcoming version 1.1.0 (which you can try here: It allows zooming the graph and then keeping the selected zoom level.

Messages In This Thread
RE: Fixed graph size and position instead of aspect ratio - by Sebastian Staacks - 09-23-2018, 06:53 PM

Forum Jump: