SciChart® the market leader in Fast WPF Charts, WPF 3D Charts, and iOS Chart & Android Chart Components

0 votes
15 views

Hi,

I was trying to get the max value on the y axis for the visible window, so that I can manually scale the y axis visible range (so I can control the increments and the y axis maximum). To get the max y data in the window, I’ve written in Kotlin:

var coordinateCalc = xUoAxes[0].createCoordinateCalculatorFrom(xUoAxes[0].visibleRange) //get visible range of coordinates
var coordMin = coordinateCalc.minAsDouble //debug var
var coordMax = coordinateCalc.maxAsDouble //debug var
var dataRange = yUoAxes.getAxisById("uoId").dataRange //debug var
var test = mapOf("test" to coordinateCalc)  //create map for getWindowedYRange, providing the coordinateCalculator
var windowedYRangeUo = yUoAxes.getAxisById("uoId").getWindowedYRange(test)  //I think this should pass back the same value as dataRange?

However, the getWindowedYRange result is significantly different from dataRange, and while debugging, there is only a single data point in yUoAxes.

I wasn’t sure if I’m using the right function, or if I’m using it incorrectly (or if this is even the correct approach to this problem)?

Thanks,
-Andy

0 votes
22 views

Is it possible?

Or make box annotations fit screen height?
(even when zooming)

1 vote
27 views

I’m sorry I couldn’t attach images because of security.

Zoom out
VisibleRange X1 min VisibleRange X1 max
    +——————————–+ VisibleRange Y1 min
    |           |
    |           |
    |s=================e|
    |           |
    |           |
    +——————————–+ VisibleRange Y1 max

s : Point Start, e : Point End

In this state, Excute Zoom In Then “s====================e” disappears when the starting point is smaller than min and the end point is greater than max.

Zoom In : “s====================e” disappear
VisibleRange X2 min VisibleRange X2 max
    +——————————–+ VisibleRange Y2 min
    |           |
    |           |
    |           |
    |           |
    |           |
    +——————————–+ VisibleRange Y2 max

I want this chart
VisibleRange X1 min VisibleRange X1 max
    +——————————–+ VisibleRange Y2 min
    |           |
    |           |
    |===================|
    |           |
    |           |
    +——————————–+ VisibleRange Y2 max

How do I draw when a chart is not drawn at the location of a given data using “CustomRenderSeries”?
“====” is a BOX(Rectangle), not a line.

The program source used for coding.
I am currently using
renderableSeries.ResamplingMode = ResamplingMode.None;

// DataInsert.cs

var renderableSeries = new DieRenderableSeries(positionOfDie, _dieLayout);

foreach (var pl in _dieLayout.PlaneLayout._plane)
{
  Plane plane = pl.Value;
  foreach (var ba in plane._bank)
  {
    Bank bank = ba.Value;

    foreach (var matList in bank.NandMat)
    {
      var renderableSeries = new DieRenderableSeries(positionOfDie, _dieLayout);
      List<KeyValuePair<Point, Mat>> matDataList = new List<KeyValuePair<Point, Mat>>();

      foreach (var mat in matList)
      {
        mat.PointType = PointType.Start;
        matDataList.Add(new KeyValuePair<Point, Mat>(new Point(startX + mat.X1, startY + mat.Y1), mat));
      }

      var myList = matDataList.OrderBy(x => x.Key.X)
              .ThenBy(x => x.Key.Y)
               .ToList();

      var dataSeries = new MatDataSeries<double, double> { SeriesName = “Fault” };
      dataSeries.AcceptsUnsortedData = false;
      using (dataSeries.SuspendUpdates())
      {
        for (var i = 0; i < myList.Count(); i++)
        {
          Point myPoint = myList[i].Key;
          dataSeries.Append(myPoint.X, myPoint.Y, myList[i].Value);
        }
      }

      sciChart.RenderableSeries.Add(renderableSeries);
      renderableSeries.DieX = dieX;
      renderableSeries.DieY = dieY;
      renderableSeries.DataSeries = dataSeries;
      renderableSeries.CountOfRenderableSeries = dataSeries.Count;
      renderableSeries.ResamplingMode = ResamplingMode.None;
    }
  }
}

// CustomRenderableSeries.cs

for (var i = 0; i < _series.Count; i++)
{
  var data = renderPassData.PointSeries[i];
  var mat = (Mat)DataSeries.Metadata[data.Index];

  Point point = GetCoordinatesFor(data.X, data.Y);
  Point point2 = GetCoordinatesFor(data.X + mat.Width, data.Y + mat.Height);

  IBrush2D brush = _dicBrush[mat.TypeX];
  var pen = _bgndPens[mat.IsRedun && IsRedunVisibled ? 1 : 0];

  drawingHelper.DrawBox(point, point2, brush, pen, 0);
}

0 votes
29 views

I would like to be able to have a Pie Chart go to the very edge of the layout it’s inside. Currently it appears as though there is some default built-in padding around Pie Charts that cannot be overridden. I’ve tried manually specifying padding and margins both programmatically (on the SciChartSurface object itself) and in the layout XML, but that default padding still exists.

I’ve included a screenshot of the sample app to show the padding I’m talking about (circled in red).

0 votes
43 views

Hello SciChart team,

How do I serialize custom tick placement and labels, generated by TickProviderAPI and LabelProvider? Actually, the main problem is that I need to export high quality (i.e. higher than actual figure size on screen) PNG images in MVVM application and method ExportToFile(fileName, ExportType.Png, false, new Size(…, …)) produces axis ticks and labels as if they were controled by original MinorDelta and MajorDelta parameters. ExportToFile() without size parameter produces output correctly, so that must be due to not-serialized TickProvider and LabeProvider properties (?), which in exported serialized surface string does not exist.

Thank you!

1 vote
35 views

Hello,

I am currently developing an application of this type (spectrogram + audiostream) :
https://i.ibb.co/sPXMbf1/screenshot-framed-1.png

But i have one problem and one question :

Problem :

I generate the spectrum with this function :

    @JvmStatic
    fun generateSpectrum(shortArray: ShortArray) {
        val sw = Stopwatch()
        sw.start()
        val buffer = ShortValues(shortArray)

        val fft = Radix2FFT(buffer.size())
        val fftData = DoubleValues()

        fft.run(buffer, fftData)
        fftData.setSize(fftSize)
        val spectrogramItems = spectrogramValues.itemsArray
        val fftItems = fftData.itemsArray

        val spectrogramSize = spectrogramValues.size()
        val fftSize = fftData.size()
        val offset = spectrogramSize - fftSize

        System.arraycopy(spectrogramItems, fftSize, spectrogramItems, 0, offset)
        System.arraycopy(fftItems, 0, spectrogramItems, offset, fftSize)

        spectrogramDS.updateZValues(spectrogramValues)
        sw.stop()
        Log.v(TAG, "SPECTRUM : " + sw.elapsedTime.toString())
    }

It works very well to generate data from a shortarray (from microphone or saved shortarray). Except that, sometime when I launch replays, on average 1 in 10 replays will be very slow. As you can see, I put stopwatch to isolate the problems and it comes from this function. This function takes an average of 2 to 3 milliseconds in normal time to perform. When a replay is slow, this function takes on average between 6 and 8 milliseconds to execute.

Why? Do you have any ideas?

Question :

I can read data from a microphone as shown on the screenshot. I also know how to replay them by cleaning spectrogramDS and sending back the read data.

Now, let’s say I want to replay but in the form of :
What is not yet played is drawn in grey (so i don’t clean) and as the dataset plays back, it takes the same color as the recording. Basically, we see in advance the sound template that is being replayed but also where we are currently in the replay.
Is it possible ?

Thanks for you answer,
Wavely

0 votes
37 views

Hi,

In Android MVVM architecture, I am trying to @Inject ISuspendable through ViewModelModule, as I cannot pass this to my VMModel constructor.

@Module
abstract class ViewModelModule {

    @Singleton
    @Binds
    abstract fun getSuspendable(aSuspendable: ACMSuspendableImpl): ISuspendable

@Binds
    @IntoMap
    @ViewModelKey(MonitorViewModel::class)
    abstract fun bindsMonitorViewModell(monitorViewModel: MonitorViewModel): ViewModel
}


@Singleton
class ACMSuspendableImpl @Inject constructor() : ISuspendable {


    override fun decrementSuspend() {
    }

    override fun suspendUpdates(): IUpdateSuspender {
        TODO("not implemented")
    }

    override fun getIsSuspended(): Boolean {
        TODO("not implemented")
    }

    override fun resumeUpdates(p0: IUpdateSuspender?) {
    }
}

whereas my MonitorViewModel class as,

class MonitorViewModel @Inject constructor(context: Context) : BaseViewModel()  {

    @Inject
    lateinit var acmSuspend: ISuspendable


private fun loadMonitorData() {

        UpdateSuspender.using(acmSuspend) { //<! NULL ->
            iapDataSeries.append(Timestamp.valueOf(mData100Hz.getRtcTimeStamp().toString()), mData100Hz.emr.iap)
            uoColumnDataSeries.append(
                Timestamp.valueOf(mData100Hz.getRtcTimeStamp().toString()),
                mData100Hz.emr.totalVolume
            )
      }
}

How should I @Inject ISuspendable so that it should not be NULL. Please provide me some example snipped to work.
FYI,

I tried to follow the ECGViewModel but this sample used some custom solution and there is no use of DI.

BR,

Praween

0 votes
44 views

Hi,

I have medical data displaying every 1s with Date as XAxis and ml/hr as YAxis. I want to control the display to let say, 6hr window in the current display by default whereas zoom-in can go to precisely 1hr and not below that and zoom-out reset to 6hr. How can I achieve this?

FYI, my data retention is for 72hrs.

BR,
Praween K.

0 votes
47 views

I am doing SciChart development with MVVM.
I generate RenderableSeries with ViewModel, View uses Bind it and uses it.

TooltipModifier is used for tooltip display.
In this application, I want to customize and display the tooltip.

To customize using the TooltipTemplate of TooltipModifier,
It was described in the following URL.
In this method, TooltipModifier.TooltipTemplate is described in XAML in View resource.
Therefore, it is not possible to specify TooltipModifier.TooltipTemplate from ViewModel.

If you generate RenderableSeries with ViewModel,
How should I specify the TooltipTemplate?

0 votes
51 views

I have at most ten of sciChart in an layout which populated by programming. I want to screenshot by programming that layout with each chart zoom or change view by user. However, the screenshot doesn’t show graphs rather than black rectangle. Is there any option to show graph on screenshot.

0 votes
46 views

Hi, I want to know buffer structure of 2d fastline.

I use very huge data per line.(maybe about 30,000 points/1 sec are appended to a line.)

But Memory usage is different than expected.

I use fifocapacity, and It is realtime graph.

Appending data, the memory usage increases too much.

Especially, It use more memory when drawing more lines.

For example,
Assuming one line uses 100mb, the five lines use 5000mb not 500mb.

Is it right??

  • CholJin Ko asked 2 weeks ago
  • last active 2 weeks ago
0 votes
59 views

I was curious, and had mentioned this in another thread, but verified what I thought. My first SciChart instance is drawing in DirectX and subsequent charts are not. Please see attached. Each chart is being created and placed inside a tabitem.

I used the suggested annotation to show the version being used (from the support forum) and found why my images are not as crisp in most of my charts.

s3d:DirectXHelper.TryApplyDirectXRenderer="True"
s3d:DirectXHelper.FallbackType="{x:Type s:HighQualityRenderSurface}"
1 vote
52 views

In the designer I’m seeing this. It doesn’t seem to affect the application; however, I can’t see any of my XAML in the designer because of this problem. Also, I’m having a strange intermittent issue with multiple instances of the chart in my UI not being as smooth and sharp after adding a few charts.

DllNotFoundException: Unable to load DLL ‘sharpdx_direct3d11_1_effects_x86.dll’: The specified module could not be found. (Exception from HRESULT: 0x8007007E)

at SciChart.Drawing.DirectX.Context.D3D11.DirectXHelper.LTC.J(Object D, DXErrorEventArgs I)
at SciChart.Drawing.DirectX.Context.D3D11.Direct3D11RenderSurface.RecreateSurface()
at SciChart.Drawing.Common.RenderSurfaceBase.RenderSurfaceSizeChanged(Object sender, SizeChangedEventArgs sizeChangedEventArgs)
at System.Windows.SizeChangedEventArgs.InvokeEventHandler(Delegate genericHandler, Object genericTarget)
at System.Windows.RoutedEventArgs.InvokeHandler(Delegate handler, Object target)
at System.Windows.RoutedEventHandlerInfo.InvokeHandler(Object target, RoutedEventArgs routedEventArgs)
at System.Windows.EventRoute.InvokeHandlersImpl(Object source, RoutedEventArgs args, Boolean reRaised)
at System.Windows.UIElement.RaiseEventImpl(DependencyObject sender, RoutedEventArgs args)
at System.Windows.UIElement.RaiseEvent(RoutedEventArgs e)
at System.Windows.FrameworkElement.OnRenderSizeChanged(SizeChangedInfo sizeInfo)
at System.Windows.ContextLayoutManager.fireSizeChangedEvents()
at System.Windows.ContextLayoutManager.UpdateLayout()
at System.Windows.UIElement.UpdateLayout()

Here’s the XAML for my chart

        <!-- Chart  -->
    <s:SciChartSurface Grid.Row="1" Grid.Column="1"                                   
                       Name="DoseChart"
                       s3d:DirectXHelper.TryApplyDirectXRenderer="True"
                       s3d:DirectXHelper.FallbackType="{x:Type s:HighQualityRenderSurface}"
                       RenderableSeries="{s:SeriesBinding Measurements}"
                       Annotations="{s:AnnotationsBinding Annotations}"
                       Style="{StaticResource ResourceKey=SurfaceStyle}"                                                      
                       GridLinesPanelStyle="{StaticResource ResourceKey=GridLinesPanelStyle}">


        <!-- Distance Axis-->
        <s:SciChartSurface.XAxis>
            <s:NumericAxis AxisTitle="Distance (cm)"
                           FontFamily="Arial" FontSize="12"
                               FlipCoordinates="False"
                               GrowBy="0.05, 0.05"
                               ScientificNotation="None" 
                               s:CursorModifier.AxisLabelContainerStyle="{StaticResource CursorModAxisLabelStyle}"
                               s:CursorModifier.AxisLabelTemplate="{StaticResource CursorModAxisLabelTemplate}"
                               Style="{DynamicResource ResourceKey=DistanceAxisStyle}" />
        </s:SciChartSurface.XAxis>

        <!-- Dose Axis -->
        <s:SciChartSurface.YAxis>
            <s:NumericAxis AxisTitle="Dose (%)"
                           FontFamily="Arial"
                               GrowBy="0.05, 0.05" 
                               Style="{DynamicResource ResourceKey=DoseAxisStyle}"
                               s:CursorModifier.AxisLabelContainerStyle="{StaticResource CursorModAxisLabelStyle}"
                               s:CursorModifier.AxisLabelTemplate="{StaticResource CursorModAxisLabelTemplate}" />
        </s:SciChartSurface.YAxis>

        <!-- Modifiers (zoom, panning, tooltips, cursor) -->
        <s:SciChartSurface.ChartModifier>
            <s:ModifierGroup>
                <s:RubberBandXyZoomModifier IsAnimated="True" IsXAxisOnly="False" />
                <s:ZoomExtentsModifier ExecuteOn="MouseDoubleClick" />
                <s:ZoomPanModifier ExecuteOn="MouseRightButton" />
                <s:MouseWheelZoomModifier ActionType="Zoom" XyDirection="XYDirection" />
                <s:XAxisDragModifier DragMode="Scale" />
                <s:YAxisDragModifier DragMode="Scale" />
                <s:TooltipModifier x:Name="ChartTooltip" IsEnabled="True" />
                <s:CursorModifier x:Name="ChartCursor" IsEnabled="False" ShowAxisLabels="True" Foreground="Red" />
            </s:ModifierGroup>
        </s:SciChartSurface.ChartModifier>

    </s:SciChartSurface>
0 votes
64 views

Hi I am trying to create a vertical line annotation with MVVM annotationsbinding – this is due to having a chart group with 2 SciChartSurfaces sharing one X axis.

I have added a VerticalLineAnnotationViewModel to my

ObservableCollection Annotations

I would like the user to be able to create a vertical line with two labels, one with the X1 position and the other with some custom text.

I have tried adding an ObservableCollection AnnotationLabels to the VerticalLineAnnotationViewModel during instantiation however they don’t seem to appear.

As an alternative I tried a CustomAnnotation called CustomVerticalLine which inherited CustomAnnotation and then created a CustomVerticalLineViewModel which inherited CustomAnnotationViewModel and then overrode the ViewType to CustomVerticalLine. This displayed the two labels but then I couldn’t bind to the X1 value or the text property.

What am I doing wrongly, could anyone help please?

Thanks

0 votes
0 answers
46 views

Turn off the phone permission, the chart shows the error, why, can you solve it?
Only when this permission is opened does it appear normal

0 votes
54 views

I want to display a character string on the X axis.

DataSeries can be realized by using XyDataSeries <sting, double> in ViewModel.

What is used for SciChartSurface.XAxis in View?

0 votes
52 views

I have a DateTime X Axis, to which I have added a custom label provider – namely to convert UTC display time to LocalTime.

This works just fine for the AxisLabels, but I also have vertical line annotations and they are NOT using the label provider and are thus showing UTC times.

Is there any way to make the vertical line annotations use the same label provider? Or some way to override the vertical line annotation label function to set the time to local?

Picture Attached.

0 votes
50 views

I want to display the entire chart from ViewModel with MVVM.

I am developing it with MVVM.
In View, if you want to display the whole chart by double clicking the mouse, it can be realized by using ZoomExtentsModifier.

I want to realize the same thing from ViewModel.

How can I do it?

0 votes
50 views

I have several BandRenderableSeriesViewModel in my chart that the user can click on to select. The issue is that they pop up into the foreground when selected and hide everything else that is now behind them. Is there a way to keep them where they are upon selection?

0 votes
46 views

Or say, how can I prevent movement of HorizontalLineAnnotation when dragging the grip of X1(typically the left grip)?

0 votes
57 views

I’m trying to add annotations on a chart but they are rendering above my legend.

Initially (similar to most of the demo code I’ve seen), I setup my modifiers, then created my series and animated them in — then added my annotations (adding to annotationGroup). This created a timeline of blank chart surface with legend (good so far), annotations popping in before the chart series animated in (weird / not good) and on TOP of the legend (really bad), then the animation of the series after that.

I’ve tried about everything I can think of and the best I’ve been able to do is use a completion block of the animation rendering the series — and moved my chart modifiers (and legend) into that completion block. If I put the annotations in the completion block, they will render after the chart modifier and I have the same problem (even if placed after the chart modifiers). I have to set the annotations before the animation, and then the chart modifier in the completion block will work and the legend will be above the . Of course, this is a bit odd too — as first my annotations pop up by themselves on the blank surface, followed by my series animating in, then at the end of the 2 second animation, the legend just pops in.

I really would like my legend to be rendered first on the blank surface and the annotations and chart series to animate in together under my legend. I’m gathering that’s unlikely (at least the animation part) — but is there anyway I can place my legend first and still have the annotations go under it? It feels like the layers should be: modifiers > annotations > rendered series. I also I’ve read this order before in some WPF docs I believe, but doesn’t seem to be respected on iOS?

UPDATE: My current work around isn’t sufficient because I really need access to the renderable series to create the annotations which means I really can’t defer my chart modifiers (i.e. legend) until after the annotations. Additionally, if I need to update (remove / re-add) an annotation due to a series being deactivated in the legend, now my annotations are on top of the legend again.

0 votes
51 views

I am placing annotations at the top of every bar in a stacked bar graph (and a standard bar graph on another screen) showing the total of all the stacked bars by iterating through my data, generating the sum, and placing it at the correct x,y (an incredibly manual process that seems like there should be much easier to do but I found no other way to do it – if there is a better way, I would love to hear it, but that’s a secondary issue and not my current problem).

I also have a legend where the user can select / deselect series.

When the user selects/deselects a series from the legend, I need to hide all my annotations and then recreate them because the sums of the stacked bars has changed (or if no bars are showing, remove my annotation completely). My assumption is I could reiterate through my data and check series to see if they are visible (isVisible) and recalculate the sums and recreate the annotations (another very manual process but I can probably work it out).

My primary problem is I see no way for me to intercept that this legend event occurred. The series get hidden internally and I never have a chance to do anything with the annotations. It seems like this may be doable on other platforms but I’m at a loss on iOS. There is no delegate / block event handler / etc.

Any thoughts?

0 votes
61 views

Hi!

I’ve tried to access the values to print them in a different view, but I cant reach them. So my question is there a specific way to reach them?

0 votes
0 answers
76 views

I have a simple chart using a an SCIDateTimeAxis to display dates along the x-axis. In some situations, the labels displayed along this x-axis are way too close together. Please see attached screenshot. I was wondering whether there is a property somewhere I can configure to increase the required “culling” space between labels? Or, failing that, what would I need to implement myself to somehow drop some of the displayed labels in order to make them more readable?

0 votes
74 views

Hello, I have added YAxisDragModifier and ZoomPanModifier to my surface and when I try to drag on Y axis I can move the X axis too and that is not the behavior that I was trying to get. I want when I drag/move YAxis not to move on the YAxis also.

Here is my code:

Surface.ChartModifiers.Add(new PinchZoomModifier());
Surface.ChartModifiers.Add(new ZoomExtentsModifier());
Surface.ChartModifiers.Add(new YAxisDragModifier { DragMode = AxisDragModifierBase.AxisDragMode.Pan });
Surface.ChartModifiers.Add(new XAxisDragModifier { DragMode = AxisDragModifierBase.AxisDragMode.Pan, ClipModeX = ClipMode.None });
Surface.ChartModifiers.Add(new ZoomPanModifier
{
Direction = Direction2D.XDirection,
ZoomExtentsY = false
});

Here is the video with the behavior:
VIDEO: https://drive.google.com/file/d/1kbYi2voKNvHD5J7D6-XDw7OJx4IwlEqr/view

Help please!

0 votes
78 views

Hello everyone.

I have 2 stacked horizontally charts with

 .withMotionEventsGroup("ModifiersSharedEventsGroup").withReceiveHandledEvents(true)

so they drag and zoom in same way.

But when i put one finger on first chart, second finger on second chart – then total apocalypse happens.
Is it possible to zoom it, like two fingers on one chart or disable zoom in that situation, so charts will have no conflict?

(I think both chart just dragging in different directions in my case, but because they are linked – everything just shakes)

Edit:

Collections.addAll(mSciChartMainSurface.getChartModifiers(), sciChartBuilder.newModifierGroup()
                        .withPinchZoomModifier().withXyDirection(Direction2D.XDirection).withScaleFactor(SCALE_FACTOR_X_AXIS).build()
                        .withZoomPanModifier().withReceiveHandledEvents(true).withXyDirection(Direction2D.XDirection).build()
                        .withMotionEventsGroup(MODIFIER_SHARED_EVENTS_GROUP_NAME).withReceiveHandledEvents(true)
                        .withXAxisDragModifier().withReceiveHandledEvents(true).withDragMode(AxisDragModifierBase.AxisDragMode.Pan).build()
                        .build());



Collections.addAll(mSciChartBotIndicatorSurface.getChartModifiers(), sciChartBuilder.newModifierGroup()
                    .withMotionEventsGroup(MODIFIER_SHARED_EVENTS_GROUP_NAME).withReceiveHandledEvents(true)
                    .withPinchZoomModifier().withXyDirection(Direction2D.XDirection).withScaleFactor(SCALE_FACTOR_X_AXIS).build()
                    .withZoomPanModifier().withReceiveHandledEvents(true).withXyDirection(Direction2D.XDirection).build()
                    .withXAxisDragModifier().withReceiveHandledEvents(true).withDragMode(AxisDragModifierBase.AxisDragMode.Pan).build()
                    .build());
0 votes
75 views

Hi, i am developping a spectogram, screenshot : https://i.ibb.co/7CPTZbg/screenshot-framed.png

I get the same result from your showcase, now there is some things i want to change but can’t resolve to know how to :
– How can i change data direction to spread from left to right ? (currently right to left)
– How can i clear FastUniformHeatmapRenderableSeries ? Method clear doesn’t work
– How can we set width of FastUniformHeatmapRenderableSeries’s layout to be fixed to a specific seconds number ? (example : there is 10 seconds of data between left and right)

Thank you,
Wavely

0 votes
65 views

I am developing an application which can receive the data from an ECG circuit, then transmit that data through Bluetooth into my phone application. My phone application would then display the ECG graph. I tried downloading the ECG demo example and it works find on its own. I am trying to incorporate that into my own project and see if it works. However I have been getting errors. Please help me out! Thank you!

1 vote
81 views

I’m trying to update to the latest nuget package and getting

Severity Code Description Project File Line Suppression State
Error Failed to fetch results from V2 feed at ‘https://nuget.telerik.com/nuget/Packages(Id=’SciChart’,Version=’5.2.2.11833′)’ with following message : Response status code does not indicate success: 401 (Logon failed.).
Response status code does not indicate success: 401 (Logon failed.).

I haven’t changed anything that I’m aware of. Ideas?

0 votes
64 views

Hi,

I am currently using SciChartDebugLogger to enable logging but I am not sure what information the vararg provides

     public void logInfo(String tag, String stringFormat, Object... args) {  }

what does the arg object provide? can it be converted to a readable string format? what does the string format mean?

0 votes
72 views

I have many users who have been sending crash reports with this stack trace and I can’t figure out what part of our code would be triggering this since the stack trace doesn’t mention any classes that are we’ve coded. Any idea what could be triggering this based on the stack trace?

java.lang.ArrayIndexOutOfBoundsException: index
at com.scichart.core.model.IntegerValues.get(IntegerValues.java:164)
at com.scichart.charting.visuals.layout.CanvasLayout.getChildDrawingOrder(CanvasLayout.java:75)
at android.view.View.populateAccessibilityNodeInfoDrawingOrderInParent(View.java:7053)
at android.view.View.onInitializeAccessibilityNodeInfoInternal(View.java:7006)
at android.view.ViewGroup.onInitializeAccessibilityNodeInfoInternal(ViewGroup.java:3232)
at android.view.View.onInitializeAccessibilityNodeInfo(View.java:6622)
at android.view.View.createAccessibilityNodeInfoInternal(View.java:6581)
at android.view.View.createAccessibilityNodeInfo(View.java:6566)
at android.view.accessibility.AccessibilityRecord.setSource(AccessibilityRecord.java:145)
at android.view.accessibility.AccessibilityRecord.setSource(AccessibilityRecord.java:119)
at android.view.View.onInitializeAccessibilityEventInternal(View.java:6518)
at android.view.View.onInitializeAccessibilityEvent(View.java:6506)
at android.view.View.sendAccessibilityEventUncheckedInternal(View.java:6371)
at android.view.View.sendAccessibilityEventUnchecked(View.java:6356)
at android.view.View$SendViewStateChangedAccessibilityEvent.run(View.java:23903)
at android.view.View$SendViewStateChangedAccessibilityEvent.runOrPost(View.java:23936)
at android.view.View.notifyViewAccessibilityStateChangedIfNeeded(View.java:9488)
at android.view.View.setFlags(View.java:11685)
at android.view.View.setVisibility(View.java:8082)
at com.scichart.charting.visuals.annotations.AnnotationBase$17.run(AnnotationBase.java:268)
at android.os.Handler.handleCallback(Handler.java:836)
at android.os.Handler.dispatchMessage(Handler.java:103)
at android.os.Looper.loop(Looper.java:208)
at android.app.ActivityThread.main(ActivityThread.java:6267)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1063)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:924)

0 votes
81 views
      <s:SciChartSurface.Annotations>
            <s:BoxAnnotation X1="25" X2="75" Y1="0" Y2="100" Background="#33FFFFFF" 
                BorderBrush="#55FFFFFF" BorderThickness="3" Padding="5">

                <s:BoxAnnotation.Template>

                    <ControlTemplate TargetType="s:BoxAnnotation">


                        <Border x:Name="PART_BoxAnnotationRoot" 
           Margin="{TemplateBinding Margin}"
           Background="{TemplateBinding Background}"
           BorderBrush="{TemplateBinding BorderBrush}"
           BorderThickness="{TemplateBinding BorderThickness}"
           CornerRadius="{TemplateBinding CornerRadius}">
                            <Viewbox Margin="{TemplateBinding Padding}" >
                                <TextBlock Text="Hello CustomAnnotation World!"></TextBlock>

                            </Viewbox>
                        </Border>

                    </ControlTemplate>
                </s:BoxAnnotation.Template>
            </s:BoxAnnotation>
        </s:SciChartSurface.Annotations>

by below tag or a code?

  • bar asked 3 weeks ago
  • last active 3 weeks ago
1 vote
76 views

Hi, I’m a software engineer. My organization is ready to purchase your solution for our project(Android, IOS), but I have some questions:
1. Can I get a callback when the visible area on the x axis changes? This is necessary to dynamically upload data to the end of the graph when the user scrolls back.
2. Change the position of the tooltip and place in the upper corner of the chart?
Thank you for your time and hope for further cooperation.
Evgeniy Grishko, software engineer.

1 vote
83 views

Hello everyone.

I have chart with adding data every second.

What i want to do:
– by dragging finger left, right – chart scrolls left and right (can go to past data, etc)
– by two fingers zoom gesture – it zooms (only horizontally with autorange by Y axis)
– i set a visible range limit to the right in this way: user can scroll to the right xMax to be in the middle (currently this part not working – and axis zooming, when i continue scrolling to the right)

I tried a lot of different modifiers, but none of them was ok.

My setup:

lineDataSeries.addObserver(new IDataSeriesObserver() {
            @Override
            public void onDataSeriesChanged(IDataSeries<?, ?> iDataSeries, int i) {

                long addTime = 30_000 * currentTimeframe;

                runOnUiThread(() -> {
                    DateRange dateRange = new DateRange();

                    dateRange.setMinMax(new Date(0), new Date(lineDataSeries.getXRange().getMax().getTime() + addTime));

                    mSciChartSurface.getXAxes().getDefault().setVisibleRangeLimit(dateRange);
                });
            }
        });

final DateAxis dateAxis = sciChartBuilder.newDateAxis()
            .withAutoRangeMode(AutoRange.Never)
            .withDrawMajorTicks(true)
            .withDrawMinorTicks(false)
            .withDrawMinorGridLines(false)
            .withAutoFitMarginalLabels(false)
            .withTextFormatting("HH:mm:ss")
            .build();
    dateAxis.setMinimalZoomConstrain(25_000L * currentTimeframe); // 25 - 300 points
    dateAxis.setMaximumZoomConstrain(300_000L * currentTimeframe);

final NumericAxis yAxis = sciChartBuilder.newNumericAxis()
            .withAutoRangeMode(AutoRange.Always)
            .withGrowBy(new DoubleRange(0.1d, 0.1d))
            .withTextFormatting("#.000000")
            .withAutoFitMarginalLabels(false)
            .withDrawMinorTicks(false)
            .withDrawMinorGridLines(false)
            .build();
    yAxis.setMinimalZoomConstrain(0d);

ModifierGroup additionalModifiers = sciChartBuilder.newModifierGroup()
            .withPinchZoomModifier().withXyDirection(Direction2D.XDirection).withScaleFactor(2).build()
            .withZoomPanModifier().withReceiveHandledEvents(true).withXyDirection(Direction2D.XDirection).withClipModeX(ClipMode.ClipAtMax).build()
            //.withZoomExtentsModifier().withReceiveHandledEvents(true).withXyDirection(Direction2D.XDirection).build()
           //
            .withXAxisDragModifier().withReceiveHandledEvents(true).withDragMode(AxisDragModifierBase.AxisDragMode.Pan).withClipModeX(ClipMode.ClipAtMax).build()
            //.withYAxisDragModifier().withReceiveHandledEvents(false).withDragMode(AxisDragModifierBase.AxisDragMode.Scale).build()
            .build();
0 votes
69 views

Hello everyone.

I have a candlestick chart with date x-axis and double y-axis.
While scrolling to the left im loading past history and showing it – everything works fine.

Once i have below crash:

What can cause it?
Can not find anything in google.

01-22 10:23:31.490 28770-28770/com.test.livedataperformance E/InputEventReceiver: Exception dispatching input event.
01-22 10:23:31.490 28770-28770/com.test.livedataperformance D/AndroidRuntime: Shutting down VM
01-22 10:23:31.490 28770-28770/com.test.livedataperformance E/AndroidRuntime: FATAL EXCEPTION: main
Process: com.test.livedataperformance, PID: 28770
java.lang.UnsupportedOperationException: Unsupported search mode
at com.scichart.data.model.SciListUtil.longFindIndex(Native Method)
at com.scichart.data.model.SciListUtil.a(SourceFile:39)
at com.scichart.data.model.SciListUtil$b.findIndex(SourceFile:3044)
at com.scichart.data.model.SciListFactory$i.a(SourceFile:3141)
at com.scichart.data.model.SciListFactory$i.findIndex(SourceFile:3126)
at com.scichart.charting.model.dataSeries.XDataSeries.a(SourceFile:273)
at com.scichart.charting.model.dataSeries.XDataSeries.getIndicesXRange(SourceFile:241)
at com.scichart.charting.model.dataSeries.XDataSeries.getWindowedYRange(SourceFile:208)
at com.scichart.charting.visuals.renderableSeries.BaseRenderableSeries.getYRange(SourceFile:1027)
at com.scichart.charting.visuals.axes.rangeCalculators.RangeCalculationHelperBase.getWindowedYRange(SourceFile:225)
at com.scichart.charting.visuals.axes.AxisBase.getWindowedYRange(SourceFile:1098)
at com.scichart.charting.visuals.SciChartSurface.a(SourceFile:1116)
at com.scichart.charting.visuals.SciChartSurface.zoomExtentsY(SourceFile:1167)
at com.scichart.charting.modifiers.ZoomPanModifier.a(SourceFile:202)
at com.scichart.charting.modifiers.ZoomPanModifier.onScroll(SourceFile:176)
at android.view.GestureDetector.onTouchEvent(GestureDetector.java:619)
at com.scichart.charting.modifiers.GestureModifierBase.onTouch(SourceFile:80)
at com.scichart.charting.modifiers.ModifierGroup.onTouch(SourceFile:189)
at com.scichart.core.utility.touch.MotionEventManager.c(SourceFile:140)
at com.scichart.core.utility.touch.MotionEventManager.a(SourceFile:39)
at com.scichart.core.utility.touch.MotionEventManager$a$1.a(SourceFile:224)
at com.scichart.core.utility.touch.MotionEventManager$a$1.execute(SourceFile:221)
at com.scichart.core.utility.touch.MotionEventManager$a.a(SourceFile:211)
at com.scichart.core.utility.touch.MotionEventManager$a.onTouchEvent(SourceFile:183)
at com.scichart.charting.visuals.SciChartSurface.onTouchEvent(SourceFile:1251)
at android.view.View.dispatchTouchEvent(View.java:9300)
at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2547)
at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2240)
at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2553)
at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2254)
at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2553)
at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2254)
at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2553)
at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2254)
at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2553)
at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2254)
at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2553)
at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2254)
at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2553)
at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2254)
at com.android.internal.policy.PhoneWindow$DecorView.superDispatchTouchEvent(PhoneWindow.java:2403)
at com.android.internal.policy.PhoneWindow.superDispatchTouchEvent(PhoneWindow.java:1737)
at android.app.Activity.dispatchTouchEvent(Activity.java:2812)
at androidx.appcompat.view.WindowCallbackWrapper.dispatchTouchEvent(WindowCallbackWrapper.java:69)
at com.android.internal.policy.PhoneWindow$DecorView.dispatchTouchEvent(PhoneWindow.java:2364)
at android.view.View.dispatchPointerEvent(View.java:9520)
at android.view.ViewRootImpl$ViewPostImeInputStage.processPointerEvent(ViewRootImpl.java:4242)
at android.view.ViewRootImpl$ViewPostImeInputStage.onProcess(ViewRootImpl.java:4095)
at android.view.ViewRootImpl$InputStage.deliver(ViewRootImpl.java:3641)
at android.view.ViewRootImpl$InputStage.onDeliverToNext(ViewRootImpl.java:3694)
at android.view.ViewRootImpl$InputStage.forward(ViewRoo

0 votes
95 views

I want to put one vertical line to chart, when mouse left button click inside the chart.
And, I want to put vertical line where nearest plotted X value to mouse cursor location in the chart.
No interpolation.

  • Also, I’m using RubberBandXyZoomModifier ExecuteOn=”MouseLeftButton”
    and

  • ZoomPanModifier ExecuteOn=”MouseRigthButton”

What is the best Modifier to use?
And how can it set like that?

0 votes
0 answers
67 views

java.lang.NullPointerException: Attempt to invoke virtual method 'boolean android.view.GestureDetector.onTouchEvent(android.view.MotionEvent)' on a null object reference
at com.scichart.charting.modifiers.GestureModifierBase.onTouch(SourceFile:80)
at com.scichart.core.utility.touch.MotionEventManager.c(SourceFile:140)
at com.scichart.core.utility.touch.MotionEventManager.a(SourceFile:39)
at com.scichart.core.utility.touch.MotionEventManager$a$1.a(SourceFile:224)
at com.scichart.core.utility.touch.MotionEventManager$a$1.execute(SourceFile:221)
at com.scichart.core.utility.touch.MotionEventManager$a.a(SourceFile:211)
at com.scichart.core.utility.touch.MotionEventManager$a.onTouchEvent(SourceFile:183)
at com.scichart.charting.visuals.SciChartSurface.onTouchEvent(SourceFile:1237)
at android.view.View.dispatchTouchEvent(View.java:12533)
at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:3026)
at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2705)
at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:3032)
at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2662)
at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:3032)
at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2662)
at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:3032)
at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2662)
at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:3032)
at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2662)
at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:3032)
at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2662)
at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:3032)
at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2662)
at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:3032)
at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2662)
at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:3032)
at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2662)
at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:3032)
at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2662)
at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:3032)
at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2662)
at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:3032)
at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2662)
at com.android.internal.policy.DecorView.superDispatchTouchEvent(DecorView.java:461)
at com.android.internal.policy.PhoneWindow.superDispatchTouchEvent(PhoneWindow.java:1830)
at android.app.Activity.dispatchTouchEvent(Activity.java:3453)
at com.android.internal.policy.DecorView.dispatchTouchEvent(DecorView.java:419)
at android.view.View.dispatchPointerEvent(View.java:12774)
at android.view.ViewRootImpl$ViewPostImeInputStage.processPointerEvent(ViewRootImpl.java:5263)
at android.view.ViewRootImpl$ViewPostImeInputStage.onProcess(ViewRootImpl.java:5063)
at android.view.ViewRootImpl$InputStage.deliver(ViewRootImpl.java:4578)
at android.view.ViewRootImpl$InputStage.onDeliverToNext(ViewRootImpl.java:4631)
at android.view.ViewRootImpl$InputStage.forward(ViewRootImpl.java:4597)
at android.view.ViewRootImpl$AsyncInputStage.forward(ViewRootImpl.java:4737)
at android.view.ViewRootImpl$InputStage.apply(ViewRootImpl.java:4605)
at android.view.ViewRootImpl$AsyncInputStage.apply(ViewRootImpl.java:4794)
at android.view.ViewRootImpl$InputStage.deliver(ViewRootImpl.java:4578)
at android.view.ViewRootImpl$InputStage.onDeliverToNext(ViewRootImpl.java:4631)
at android.view.ViewRootImpl$InputStage.forward(ViewRootImpl.java:4597)
at android.view.ViewRootImpl$InputStage.apply(ViewRootImpl.java:4605)
at android.view.ViewRootImpl$InputStage.deliver(ViewRootImpl.java:4578)
at android.view.ViewRootImpl.deliverInputEvent(ViewRootImpl.java:7304)
at android.view.ViewRootImpl.doProcessInputEvents(ViewRootImpl.java:7273)
at android.view.ViewRootImpl.enqueueInputEvent(ViewRootImpl.java:7234)
at android.view.ViewRootImpl$WindowInputEventReceiver.onInputEvent(ViewRootImpl.java:7410)
at android.view.InputEventReceiver.dispatchInputEvent(InputEventReceiver.java:247)
at android.os.MessageQueue.nativePollOnce(Native Method)
at android.os.MessageQueue.next(MessageQueue.java:326)
at android.os.Looper.loop(Looper.java:165)
at android.app.ActivityThread.main(ActivityThread.java:6806)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:547)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:873)

1 vote
74 views

enter image description here

we want z axis up but when we draw Y axis come up hot to solve this

        short[] shortArrayz;
        int lengthz;
        short[,] shortArray = new short[100, 15];
        using (BinaryReader b = new BinaryReader(
                    File.Open("F971-181223-10.MNZ", FileMode.Open)))
        {
            // 2.
            // Position and length variables.
            int pos = 0;
            // 2A.
            // Use BaseStream.

            //    pos += sizeof(int);
            //  pos += sizeof(int);
            lengthz = (int)b.BaseStream.Length;
            shortArrayz = new short[lengthz];


            //    Console.WriteLine(length);
            while (pos < lengthz)
            {
                // 3.
                // Read integer.

                /*

                for (int i = 0; i < 100; i++)
                {
                    for (int j = 0; j < 15; j++)
                    {

                        shortArray[i, j] = b.ReadInt16();
                        Console.WriteLine(shortArray[i, j]);
                    }
                }
                */

                shortArrayz[pos] = b.ReadInt16();


                // 4.
                // Advance our position variable.
                pos += sizeof(short);
            }
        }


        //100x15 lik dosya için        
        int xSize = 15;
        int ySize = 100;


        var meshDataSeries = new UniformGridDataSeries3D<double>(xSize, ySize)
        {
            SeriesName = "Uniform Surface Mesh",
        };




        int h = 0;

        for (int x = 0; x <xSize; x++)
            for (int y = 0; y < ySize; y++)
        {             
            {
                double z =(double) shortArrayz[h];
            meshDataSeries[y, x] = z;

                h += sizeof(short);               
            }
        }


        // Assign the DataSeries to the char
        surfaceMeshRenderableSeries.DataSeries =meshDataSeries;

2) In contour graph values is coorect but seems like it is sliced how to solve this?

Codes are attached

  • bar asked 4 weeks ago
  • last active 4 weeks ago
1 vote
70 views

If you set limit on range of axis, the pinch gesture will not work correctly.
Pinch the chart and hold for a while (about less than 1 sec), the chart will resize to the limit value you set on the axis.

You can change code of OscilloscopeFragment.java#106 in Examples to below to reproduce this problem.

final IAxis xBottomAxis = sciChartBuilder.newNumericAxis()
                    .withAutoRangeMode(AutoRange.Never)
                    .withAxisTitle("Time (ms)")
                    .withVisibleRange(new DoubleRange(2.5, 4.5))
                    .withVisibleRangeLimit(0,20)   // this will help reproduce the problem
                    .build();
1 vote
0 answers
92 views

Hello everyone,

I have a chart which has data added to its plots at inconsistent time intervals.
My intention is to be able to limit the displayed data by their x-values, for example only showing the last 60 seconds. At the same time I wish to be able to zoom/pan back to the old data, so I can not discard it, and from what I saw “VisibleRangeLimit” did not work this way either, as it limited every zoom or pan action to the given range limit. Mainly I need the auto ranging to limit the display to my limits (and return the graph to its scrolling mode), while every other zoom/pan interaction stops the scrolling without being limited.

The solution I came up with for this is to “move” the VisibleRange of the axis whenever new data points outside the current displayed range are added to the chart’s plots. (For example if a point is plotted at 61 seconds, the VisibleRange moves to min=1 and max=61.)

I made this into an axis class, which inherits the NumericAxis and uses DataRangeChanged to change the VisibleRange on data changes and VisibleRangeChanged to react to auto ranging and zooming/panning.

private void UpdateVisibleRange()
{
    DoubleRange visibleRange = (DoubleRange)GetMaximumRange();
    visibleRange.Min = visibleRange.Max > ViewLimit ? visibleRange.Max - ViewLimit : 0;
    VisibleRange = visibleRange;
}

// DataRangeChanged += DataRangeChangedHandler;
private void DataRangeChangedHandler(Object sender, EventArgs e)
{
    if (IsAutoRangeActive)
    {
        UpdateVisibleRange();
        IsAutoRangeActive = true;
    }
}

// VisibleRangeChanged += VisibleRangeChangedHandler;
private void VisibleRangeChangedHandler(Object sender, VisibleRangeChangedEventArgs e)
{
    if (base.AutoRange == AutoRange.Always)
    {
        base.AutoRange = AutoRange.Never;
        UpdateVisibleRange();
        IsAutoRangeActive = true;
    }
    else if (IsAutoRangeActive)
    {
        IsAutoRangeActive = false;
    }
}

(Only relevant code shown.)

How it works:
If the VisibleRange of the axis is changed through other means than new data being plotted or AutoRange being set to Always, a zoom/pan action is assumed and IsAutoRangeActive gets set to false.
If AutoRange is set to Always it causes the VisibleRange to change, which causes a VisibleRangeChanged event to trigger, activating IsAutoRangeActive and recalculating the VisibleRange to fit the desired view limit.
IsAutoRangeActive being true causes data range changes from new data to call UpdateVisibleRange, which moves the displayed range according to the view limit. As changes to the VisibleRange cause a VisibleRangeChanged event to trigger, which sets IsAutoRangeActive to false, IsAutoRangeActive needs to be reset to true after the VisibleRange has been updated in the handler.

The problem:
It all seemed to work fine until I noticed that this method does not update the actually displayed axis VisibleRange to the latest range. It uses the previous VisibleRange whenever the DataRange changes, despite VisibleRange apparently being set to the correct values. For example, if the previous range was at “min=1, max =61”, and the next is at “min=2, max=62”, the chart’s x-axis would display “min=1, max=61” instead.
It seems that “VisibleRange = visibleRange;” in UpdateVisibleRange, called from DataRangeChangedHandler, does not update the displayed range.
It works fine if the change is trigger by setting AutoRange to Always, and the x-axis’ VisibleRange corrects itself when the y-axis is modified.

(Overall this seems like quite a crude solution to me, and I wonder if there isn’t a better way of achieving this. Maybe I overlooked something?)


EDIT:
I got around the issue by using the ViewportManager as recommended and described in Tutorial 06 – Adding Realtime Updates (Scrolling Realtime Charts, see ScrollingViewportManager), though I had to make a change to make it work with my modifiers, which rely on AutoRange being set to “Always” to reset the view to scrolling mode (this way I can reset the x and y axis to extends independently).

private class ScrollingViewportManager : DefaultViewportManager
{
    public Double ViewLimit = 1.0;

    protected override IRange OnCalculateNewXRange(IAxis xAxis)
    {
        DoubleRange dataRange = null;
        if (xAxis.AutoRange == AutoRange.Never) // Zoom/Pan
        {
            dataRange = xAxis?.VisibleRange?.AsDoubleRange();
        }
        else // X-Value limited AutoRange
        {
            dataRange = xAxis?.DataRange?.AsDoubleRange();
            if (dataRange != null)
            {
                dataRange.Min = (dataRange.Max > ViewLimit) ? (dataRange.Max - ViewLimit) : 0.0;
                dataRange.Max = (dataRange.Max == dataRange.Min) ? (dataRange.Min + 1.0) : dataRange.Max;

                Double rangeWidth = dataRange.Max - dataRange.Min;
                dataRange.Min -= (rangeWidth * xAxis.GrowBy.Min);
                dataRange.Max += (rangeWidth * xAxis.GrowBy.Max);
            }
        }
        if (dataRange == null)
            dataRange = new DoubleRange(0.0, ViewLimit);
        return dataRange; 
    }
}

…wonder why I didn’t think of checking for AutoRange instead of ZoomState in the ViewportManager earlier.
While I haven’t tested it thoroughly yet, it seems to work the way I intended it to.
The reason I calculate the GrowBy myself is because it otherwise uses the full DataRange (for example if you had a window of 60 seconds, GrowBy of (0.0, 0.1) and 1000 seconds of data, it would move the data completly out of view, “showing” the timespan from 1040 to 1100).

For me the problem is solved by using a better solution to the actual problem. The question why changes to VisibleRange in the DataRangeChanged-event don’t update the chart is still open though, if someone else comes upon this problem.

0 votes
0 answers
84 views

When I run the LegendModifier example from tutorial, I just got an error

FATAL EXCEPTION: main
Process: br.cta.ipev.scicharttutorial, PID: 16941
java.lang.NoClassDefFoundError: com.scichart.charting.visuals.legend.SciChartLegend$LegendItemViewHolderAdapter*

ModifierGroup legendModifier = sciChartBuilder.newModifierGroup()
.withLegendModifier().withOrientation(Orientation.HORIZONTAL).withPosition(Gravity.TOP | Gravity.START, 16).build()
.build();
surface.getChartModifiers().add(legendModifier);
0 votes
98 views

Hey everyone,

Im using scichart in a data intensive application and have hit a problem that I haven’t been able to find a solution to.

The scope for feature is that the chart must be able to render a real time list of data points (double & timestamp) as they come in from a web service. However the chart must also be able to filter to show points that ocurred in a configurable window eg. all points within the last 5 minutes or 15 minutes or no filter.

I have business logic which generates the list of points the chart should show for the desired window. I also have an adapter that generates a diff of the old data aginst the new data to dispatch commands to the XyDataSeries.

The diff generates add, remove and update patches which the adapter applies to the XyDataSeries in the following form:
Add -> append() if data is at end of series, insertAt otherwise
Remove -> removeAt()
Update -> updateAt()

This is where I hit a problem. The removes do not happen, the only command that I can see modifying the chart is the append. I’ve tried using removeRange as well since removes often occur together but still no success.

The only way I’ve managed to get it to work is to clear all the rendered lines and redrew them which I imagine is hugely inefficient.

I’m using the UpdateSuspender to ensure that all operations complete as one.

At the moment I’m seeing no messages in Logcat and haven’t experienced any crashes and debugging with breakpoints show that the methods are being called.

Does it sound like I’m doing something wrong?

Also just to check my understanding of modifying the XyDataSeries, does it only apply updates at the end? I’ve been modifying my indices as I go so if I remove at index 1 I then assume that the series has shrunk by 1, is this the case?

Thanks for any assistance you can provide.

Edit:

A sample project that demonstrates this is attached. The provided ReadMe briefly covers the expected behaviour for the app and a run down of the classes included.

  • Keith Kirk asked 1 month ago
  • last active 4 weeks ago
0 votes
91 views

We have 2 graph surfaces with 2 Y axes on each side, but the label formatting of the axes is different. That makes the axes widths different and therefore both the graphs appear as they have different widths. Is there a way to make the axis widths fixed so the graphs can be the same size?

0 votes
94 views

Hello,

is it possible to color the curve with different color(s) after specific value(s)
to sumurise the idea, please see the illistustration in this image : https://i.stack.imgur.com/1MWKL.png

Thank you for your support

Regards

0 votes
84 views

Hi ,

Does scichart graph X-Axis supports datetime?

I am getting examples with only NumericAxis examples in internet.

So is it possible to send me some code snippet with datetime with X-Axis.

Thanks & regards,
Kartik K

  • kartik K asked 1 month ago
  • last active 1 month ago
0 votes
86 views

Hello

Currently trying this:

final NumericAxis yAxis = sciChartBuilder.newNumericAxis()
            .withAutoRangeMode(AutoRange.Never)
            .withTextFormatting("#.0000")
            .withVisibleRangeLimit(1.143, 1.146)
            .build();

Works perfectly with values .withVisibleRangeLimit(1.14, 1.15), but every time i go for more precision – range is default 0-10

Please help

Edit:
Also works fine with

.withVisibleRangeLimit(1.1433, 1.1566)

Question 2.
Is there a way to determine that live chart was scrolled by finger or by animation (when adding new point)?

0 votes
99 views

a) change y and z axis order , must be (x,y)->z,
b) the contour graph is sliced in rectangular form when colored, how to solve this?

a) we are trying product, but when I draw surface graph z data come to y axis or tooltip label,I use like this
int xSize = 15;
int ySize = 100;

        var meshDataSeries = new UniformGridDataSeries3D<double>(xSize, ySize)
        {



            SeriesName = "Uniform Surface Mesh",
        };


        int h = 0;

        for (int x = 0; x <xSize; x++)
            for (int y = 0; y < ySize; y++)
        {

            {

                double z =(double) shortArrayz[h];
             meshDataSeries[y, x] = z;

                h += sizeof(short);

            }

b) images attached, contour graph code is atteched

  • bar asked 1 month ago
  • last active 1 month ago
0 votes
116 views

I have a ViewPager which switches between Fragments that have a SciChartSurface in their layout. I have two problems with this.

  1. When swiping the ViewPager the SciChartSurface shows a black bar on its side (see attached image).

  2. When swiping I cannot achieve 60 fps on my device. Upon inspecting systrace I see scheduling delay for each frame. Upon inspecting Android profiler’s flame chart I see that SurfaceView calls android.os.BinderProxy.transact() which takes most of the time. If I change the layout of the Fragments used in ViewPager to a normal View, then android.os.MessageQueue.nativePollOnce() takes about 80% of the time, which means most of the time the CPU is idling because drawing takes up so little time.

My question is how can I solve both problems. Have I configured the SciChartSurface wrongly to get the black bars. Can I do anything to speed up changing tabs in ViewPager with SciChartSurfaces in the Fragments?


Edit 14. 1. 2019

I have attached a sample project to reproduce the problem.

0 votes
106 views

Dear SciChart Team:

I want to have two vertical lines on the graph and get the spacing of the two lines as the mouse moves,
as shown in the attached picture.

Can you provide a simple example showing the architecture of this feature?

  • Johnny Yeh asked 1 month ago
  • last active 1 month ago
0 votes
122 views

Hi guys,

Is it possible to capture the tap event when we tap on a point marker or a data point? I can see there’s a DataPointSelectionModifier for WPF, but there’s nothing for iOS. Our goal is to show a popup (tooltip) on the point marker when the user taps on it.

Thanks,
Lazar Nikolov

Showing 1 - 50 of 2k results