Skip to content

DashR DAQ IV Tracer#275

Merged
rpkyle merged 11 commits intomasterfrom
dashr-daq-iv-tracer
Aug 8, 2019
Merged

DashR DAQ IV Tracer#275
rpkyle merged 11 commits intomasterfrom
dashr-daq-iv-tracer

Conversation

@CanerIrfanoglu
Copy link
Copy Markdown
Contributor

@CanerIrfanoglu CanerIrfanoglu commented Aug 7, 2019

Issue for app: #[issue number here]

App pull request

  • This is a new app
  • I am improving an existing app (redesigns/code "makeovers")

About

Workflow

  • I have created a branch in the appropriate monorepo, and the
    elements necessary for successful deployment are in place.
  • If the app is a redesigned and/or restyled version of an
    existing gallery app, I've summarized the changes requested in the
    appropriate Streambed issue and confirm that they have been applied.
  • If the app is on the Dash Gallery portal, I have added a link to
    the GitHub repository for the source code in the portal description.
  • If the app is a reimplementation of a Python gallery app for the
    DashR gallery, the app in this PR mimics, as closely as possible,
    the style and functionality of the existing app.=
  • I have removed all Google Analytics code from the app's
    assets/ folder.

The pre-review review

I have addressed all of the following questions:

  • Does everything in my code serve some purpose? (I have removed
    any dead and/or irrelevant code.)
  • Does everything in my code have a clear purpose? (My code is
    readable and, where it isn't, it has been commented appropriately.)]
  • Am I reinventing the wheel? (I have used appropriate packages to
    lessen the volume of code that needs to be maintained.)

Copy link
Copy Markdown
Contributor

@rpkyle rpkyle left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@CanerIrfanoglu Looks great overall! Just a few requests before we can merge this one. Shouldn't take too long 🙂

Comment thread apps/dashr-daq-iv-tracer/README.md Outdated
Comment thread apps/dashr-daq-iv-tracer/README.md Outdated
Comment thread apps/dashr-daq-iv-tracer/README.md Outdated
Comment thread apps/dashr-daq-iv-tracer/app.R Outdated
Comment thread apps/dashr-daq-iv-tracer/app.R Outdated
Comment thread apps/dashr-daq-iv-tracer/app.R Outdated
***Sweep mode***

Set the sweep parameters `start`, `stop` and `step` as well as the time
spent on each step, then click on the button `START SWEEP`, the result of the
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"Start Sweep" is a little less threatening (even if the button text is capitalized) 😂

Comment thread apps/dashr-daq-iv-tracer/app.R Outdated
spent on each step, then click on the button `START SWEEP`, the result of the
sweep will be displayed on the graph.

The data is never erased unless the button `CLEAR GRAPH` is pressed, or if the
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"Clear Graph"

Comment thread apps/dashr-daq-iv-tracer/app.R Outdated

Click on theme toggle on top of the page to view dark/light layout.

You can purchase the Dash DAQ components at [
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Dash DAQ is now free, so I'd change to

You can check out the Dash DAQ components in action at

Comment thread apps/dashr-daq-iv-tracer/app.R Outdated
if (measTriggered) {

# Single data point does not draw graph,
# duplicating data to show single data point
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Interesting; why is this step necessary?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

When the voltage/current value set from the daqKnob and Single Measure is clicked, we expect having a single data point on the graph like in the python version. However, when there's only 1 data point in xdata and ydata, the callback was returning an empty graph. Just duplicating values in this scenario solved the issue. However, not sure if it is the best solution.

Screen Shot 2019-08-08 at 2 55 07 PM

Copy link
Copy Markdown
Contributor

@rpkyle rpkyle Aug 8, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah, OK; thanks for the additional detail. I think we should revisit this sometime soon, but for now it's fine. We can discuss alternatives and then just open a new, tiny PR to update later.

The main reason I bring it up is that eventually someone will face a similar issue and might conclude this is the "official" approach. Then again, maybe it's the ideal solution and I just don't realize it yet 🙂

@CanerIrfanoglu CanerIrfanoglu requested a review from rpkyle August 8, 2019 19:15
@CanerIrfanoglu
Copy link
Copy Markdown
Contributor Author

@rpkyle thank you for reviewing. Just pushed commits 1e3e188 d686966 applying the suggested changes.

@rpkyle
Copy link
Copy Markdown
Contributor

rpkyle commented Aug 8, 2019

Nice work!! 💃

@rpkyle rpkyle requested a review from KPhans August 8, 2019 19:49
Copy link
Copy Markdown
Contributor

@KPhans KPhans left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just reviewed the app. Looks good! Seems to be alot of if and else commands and seems real simple to follow. just noticed that there are alot of if else with only two options and so maybe use ifelse() rather then if({} else{}. Also, there are alot of callbacks. alot of them using the same input. Callback context can definitely be used for this app in the future. Other then that, good work. approving !

@CanerIrfanoglu
Copy link
Copy Markdown
Contributor Author

@KPhans thank you for reviewing :) Solid suggestions, definitely will look into callback_context. Guess DashR-oil-and-gas would be a good example.

@rpkyle rpkyle merged commit 6c5bb44 into master Aug 8, 2019
@rpkyle rpkyle deleted the dashr-daq-iv-tracer branch August 8, 2019 22:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants