I'm very new to Pine script. Can I set it up so that every time there is a date input, a vertical line appears to mark the date?
I'm currently using a new line to mark every date using the input name as both x coordinates.
Related
The image has the before spreadsheet with the dark background and the white spreadsheet is what I need as an end product to group the images into subjectsI’m working with camera trap images that I want to have sorted into events, or the times when one individual is being detected in front of the camera. My csv currently has columns with the image ID, the size of the image, and the createdate or time stamp. I want to have any picture occurring within two minutes of the previous to be grouped together as an assumption of that being the same individual animal so it will only be identified once. In the csv each image ID would need to be present in a single cell going horizontal across the spreadsheet with each row representing an event.
I thought there may be a way to do this using the package lubridate, but I have not found anything that has pushed me in the right direction.
Any ideas?
It could be easy to add a new column in with the Group number.
Sort the images by date and put first one Group = 1
then
if ( date [row]-date[row-1] > 2 min ) group[row]= groupe[row-1]+1
Later you can convert that values to numbers and use them to rename the images or whatever you want.
I have created the attached dashboard in powerBI. It is a monthly report. That shows the count of item each month. The dates are in this format 1/1/18, 1/2/18, 1/3/18 that the first day of every month
When I created the report powerBI are skiping one month at interval. See Pix attached.
how can i show all months?
Desired
I believe you'll need to change the "X-Axis" type to "Categorical". It looks like it's defaulting to Scalar, which makes a continuous axis and picks tick marks based on available space.
You could try decreasing the font size of the month labels since Power BI might be avoiding overlap. You could also try shortening the length of the label from MMM-YYYY to MMM-YY.
I've been stuck on this for a few days. I have an object that contains:
DateTime Start;
string State; //current state of Item "ON", "D", "SB", "OFF".
int Duration; // in seconds
I need a step chart that charts the current state of the item by time of day. The chart has time of day along the bottom. States on Y axis 1 and duration on y axis 2. I know the data is getting through, because I have a table below the chart that displays the same data.
I currently have start on Category fields and Duration on secondary axis and Status on regular axis. The main problem is it's not graphing at all.
Figured it out I had to set a switch to get the state to graph correctly on the positions. I then hid the labels and put the correct tags in place. Also when I set the date time for the x axis and set it to increment by hours it set the current day I made that change so when I handed it a day in the past it threw the whole set out as not meeting the criteria.
I have a line chart that I am building from a SQL Data Reader which is filled from stored procedure with begin and end date parameters.
When the chart is drawn the X axis lables are the day part of the date and time string that are returned. What I would like to do is change that to the hours portion when the range is less than 24 hours.
How do I go about changing the X Axis labels?
TIA
John
I don't have the code right in front of me but you should be able to do this via something like:
chart.ChartArea(0).AxisX.CustomLabels.Add
Using Zedgraph (asp.net). I have a bar graph based on datetime x points. The first bar does not have a label. The first label is at the y-axis corresponding to a day before my first day point. I am not too concerned about this. However the second label is at the second bar. I need the first bar to have a label. I do have MyPane.XAxis.Scale.IsSkipFirstLabel = false.
How do I force the first bar to have a label? Why is ZedGraph not putting a label there?
Addition:
I want '5/20' to display for the first bar instead of 5/19 under the y-axis. I don't even have an entry for 5/19.
alt text http://i50.tinypic.com/29ogx0n_th.gif
OK, I don't know if that's exactly what you need, but:
First, adjust your scale ranges manually:
zg1.MasterPane[0].XAxis.Scale.Min = (double)new XDate(2010, 05, 19);
zg1.MasterPane[0].XAxis.Scale.Max = (double)new XDate(2010, 05,30);
This will set the ranges of your scale to show one day before and one day after your data (this is needed to have extra space)
then, set the step:
zg1.MasterPane[0].XAxis.Scale.MajorStep = 1;
zg1.MasterPane[0].XAxis.Scale.FontSpec.Angle = 90f;
This will cause you will have one label for each day. In fact, this is the only way to have more or less control over the labels that appear. I've also changed the angle of labels (in normal position it would overlap).
But it would create the labels for first and last extra days too (margins). So we need to disable these two entries (now it would work, because you've set the ranges manually).
zg1.MasterPane[0].XAxis.Scale.IsSkipFirstLabel = true;
zg1.MasterPane[0].XAxis.Scale.IsSkipLastLabel = true;
If you just want to disable this first and last extra label and leave the rest to the ZedGraph, just ommit the second step. But the outcome could be sometimes unpredictable.