Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Display Make Data Count use and citation metrics #5253

Closed
djbrooke opened this issue Oct 31, 2018 · 17 comments

Comments

@djbrooke
Copy link
Contributor

commented Oct 31, 2018

After the backend for Make Data Count support is implemented in #4821, we'll need to display the metrics on the appropriate pages.

@djbrooke

This comment has been minimized.

Copy link
Contributor Author

commented May 6, 2019

When displaying metrics, we need to take into account:

  • Some installations have handles, we should display what we can for these, but we may not be able to display all the metrics
  • Some installations will have DOIs through Datacite but won't have file-level DOIs enabled so we may not be able to display all the metrics

@djbrooke djbrooke added this to UI/UX Design 💡📝 in IQSS/dataverse May 8, 2019

@TaniaSchlatter

This comment has been minimized.

Copy link
Contributor

commented Jun 10, 2019

Design doc with research, questions, mockups

@mheppler mheppler self-assigned this Jun 11, 2019

mheppler added a commit that referenced this issue Jun 12, 2019

mheppler added a commit that referenced this issue Jun 17, 2019

mheppler added a commit that referenced this issue Jun 25, 2019

@djbrooke djbrooke moved this from UI/UX Design 💡📝 to Ready 🙋 in IQSS/dataverse Jun 25, 2019

mheppler added a commit that referenced this issue Jun 25, 2019

@djbrooke djbrooke moved this from Ready 🙋 to IQSS Sprint 6/26 - 7/10 in IQSS/dataverse Jun 26, 2019

@djbrooke djbrooke added the Medium label Jun 26, 2019

@djbrooke djbrooke moved this from IQSS Sprint 6/26 - 7/10 to IQSS Team Dev 💻 in IQSS/dataverse Jun 26, 2019

mheppler added a commit that referenced this issue Jun 27, 2019

Moved metrics block on file and dataset pgs, moved some stuff around …
…to make room, added placeholder static content for dynamic MDC metrics [ref #5253]
@mheppler

This comment has been minimized.

Copy link
Contributor

commented Jun 27, 2019

Front-end for the file and dataset pgs have been revamped based on recent 5.0 mockups, in order to make some room for expanded metrics from Make Data Count.

New branch 5253-metrics-block-ui is ready to be wired up. Static placeholder content has been added to the Metrics block, ready to be connected to the back-end.

Assorted UI changes include:

  • Container div's for the top section of both pgs has been refactored to improve the use of the Bootstrap grid layout, and for the two pgs to look more consistent (further work can be done here to create a template both pgs use to keep the code and layout consistent)
  • Metrics block has been moved to a column on the right of the citation blocks
  • Publication status and version labels have been moved to their own line/block under the title, as opposed to inline at the end of the dataset title/file name
  • Cite Dataset/Data File buttons have been moved under the citations, as opposed to a column on the right side of the citation block
  • On the dataset pg, the panel component around the dataset summary section has been removed to get rid of the border around that section
  • On the file pg, the two citation blocks have been swapped in order, so the file citation is displayed first, then the dataset citation
  • (...file pg) the file preview/thumbnail/icon has been moved to the Metadata tab, and given a File Preview label
  • (...file pg) the duplicate file metadata under the citation blocks has been removed, and the tags (which were not duplicated) have been moved to the Metadata tab, and given a File Tags label, and retaining the render logic to hide the block if there are no tags

Screen Shot 2019-06-27 at 1 03 53 PM

Screen Shot 2019-06-27 at 1 04 53 PM

@mheppler mheppler removed their assignment Jun 27, 2019

@djbrooke djbrooke moved this from IQSS Team Dev 💻 to IQSS Sprint 6/26 - 7/10 in IQSS/dataverse Jun 28, 2019

@djbrooke

This comment has been minimized.

Copy link
Contributor Author

commented Jul 10, 2019

  • The change to move the preview under file metadata is a temporary change while we implement the file page redesign.

pdurbin added a commit that referenced this issue Jul 12, 2019

@pdurbin pdurbin self-assigned this Jul 12, 2019

@pdurbin pdurbin moved this from IQSS Sprint 7/10 - 7/24 to IQSS Team Dev 💻 in IQSS/dataverse Jul 12, 2019

@pdurbin

This comment has been minimized.

Copy link
Member

commented Jul 12, 2019

I started wiring up the Make Data Count back end to the front end.

First, to make it easier to work on the front end, I documented how to run an integration test to put some data in your database: 3760d31

Then I wired up downloads and views on the dataset page: bc5d512

While I was in there I noticed that the mockup above had downloads twice like this:

Screen Shot 2019-07-12 at 4 43 26 PM

I changed the second "Downloads" to "Views" and added a CSS class called "metrics-views-mdc" but I couldn't find where the classes for downloads and citations are defined.

I also notice that there's some help text that could probably be added by someone who wants to swarm on this issue. Right now the popup has placeholder text and I'm not sure why "Downloads" doesn't have a link or a question mark. Here's how it looks after my changes:

Screen Shot 2019-07-13 at 8 53 37 AM

pdurbin added a commit that referenced this issue Jul 15, 2019

pdurbin added a commit that referenced this issue Jul 18, 2019

pdurbin added a commit that referenced this issue Jul 18, 2019

@pdurbin

This comment has been minimized.

Copy link
Member

commented Jul 18, 2019

@TaniaSchlatter I just re-wrote the tooltips as promised and deployed the code to the same test server we've been using. The server is currently configured for Make Data Count so you sound see something like the screenshot below if you go to http://ec2-3-86-35-164.compute-1.amazonaws.com/dataset.xhtml?persistentId=doi:10.5072/FK2/GB9MJQ&version=1.0

Screen Shot 2019-07-18 at 4 04 48 PM

You should see tooltips like the ones below while the server is in Make Data Count mode:

metrics.dataset.title=Dataset Metrics
metrics.dataset.tip.makedatacount=Metrics collected using Make Data Count standards.
metrics.dataset.views.tip=Dataset views are combined with aggregated file views.
metrics.dataset.downloads.makedatacount.tip=Each file download (single or multiple files) increments the download count.
metrics.dataset.citations.tip=Click for a list of citation URLs.
metrics.citations.dialog.header=Dataset Citations
metrics.citations.dialog.help=Citations for this dataset are retrieved from Crossref via DataCite a using Make Data Count standards.

metrics.file.title=File Metrics
metrics.file.tip.makedatacount=Individual file downloads are tracked but this is not part of the Make Data Count standard.
metrics.file.downloads.tip=Total downloads of this file.

To give you a preview of the tooltips you should expect to see when I reconfigure this server for "default" or "out of the box" mode (not Make Data Count), this is what you'll see.

metrics.dataset.tip.default=Aggregated metrics for this dataset.
metrics.dataset.downloads.default.tip=Total aggregated downloads of files in this dataset.
metrics.file.tip.default=Metrics for this individual file.

@mheppler if you're able to pull the latest and demo some of this on your laptop, this might be easier since I'm working remotely the rest of the week.

I also wired the citations pop up to the database so that the list is no longer hard coded.

Next I guess I'll look into the tasks I mentioned previously:

  • instead of 0, 1, 2, 3, or 4 views, downloads, or citations show <5
  • use K and M for thousand and million, respectively

@TaniaSchlatter I'm not sure if you saw the note in my last comment about how I think people will be quite happy with 4 citations so I'm not sure if the "<5" is needed for citations.

I should also mention that I haven't yet figured out the backend problem I mentioned at standup yesterday about how I wasn't able to produce the JSON file of views and downloads based on logs created by Dataverse. @sekmiller and I talked about it but he didn't work on this part of the code. I'm not sure if it's not working or if the docs weren't easy enough for me to follow to install, configure, and run Counter Processor. If anyone wants to swarm on this task, IQSS/dataverse.harvard.edu#3 is highly related.

@mheppler

This comment has been minimized.

Copy link
Contributor

commented Jul 18, 2019

If we're voting on the metrics number formatting, I would say that it is unnecessary. It isn't saving very much space, and I can see all the support emails now... my dataset page says, "1.1M Downloads", where are my 99,999 other downloads?

@pdurbin

This comment has been minimized.

Copy link
Member

commented Jul 18, 2019

@mheppler well, it would be an easy way to cut scope by not implementing the metrics formatting suggested above. (And I don't know how to do it. I've been Googling a bit just now.) You're right that space isn't much of a concern. Here's a fake "views" metric with over a billion:

Screen Shot 2019-07-18 at 4 38 53 PM

The above is also consistent with the "big number formatting" we have at the installation level:

Screen Shot 2019-07-18 at 4 41 47 PM

I dunno. If OmniFaces or JSF made this super easy to do (maybe @scolapasta knows how?) I would probably just throw it in there but maybe we should consider deferring this. I'm curious what @djbrooke thinks.

The other thing I'm thinking about is how when I was a kid I was a little sad when a McDonalds would switch over from "999,862 served" one week to "millions and millions served" the next. 😄 I guess I like the precision (which you can still get from the Dataverse API, by the way, regardless of what we do in the UI).

Whoops, I'm mis-remembering how these McDonalds signs worked, I think. I just found this:

mcdonalds-1

@djbrooke

This comment has been minimized.

Copy link
Contributor Author

commented Jul 18, 2019

I believe using K and M was for internationalization purposes because it gives us extra space for those languages that have long words for "Downloads" and "Views"

@pdurbin

This comment has been minimized.

Copy link
Member

commented Jul 18, 2019

@djbrooke right, right. Ok, I'll keep Googling. /me sings "Don't Wanna Be An American Idiot"

Oh, the other thing on my todo list is to switch from stuff like jsf:rendered="#{not empty settingsServiceBean.get(':MDCLogPath')}" which makes a lot of database calls to our settingsWrapper. I'll probably do that next.

If there are any JSF experts in the house that can advise on the K and M and <5, you know where to find me.

@mheppler

This comment has been minimized.

Copy link
Contributor

commented Jul 19, 2019

Note: need to fix the CSS for the old metrics block that is still on the dataverse pg.

Screen Shot 2019-07-19 at 9 37 01 AM

pdurbin added a commit that referenced this issue Jul 19, 2019

@pdurbin

This comment has been minimized.

Copy link
Member

commented Jul 19, 2019

I just made pull request #6040

In Slack @djbrooke @TaniaSchlatter @mheppler and I decided to defer the work on

  • internationalization of large numbers. Mike linked us to https://meta.discourse.org/t/is-there-a-way-to-translate-numbers-e-g-1-3k-in-the-views-column/30374 and now I'm somewhat haunted by "No one of the 120 registered users in our forum is aware of the “K”." If Discourse hasn't figured this out yet I'm not sure we have a good solution. We'll just show 1,234,567,890 and let people translate "Views" or whatever into a word that fits in the UI.
  • "<5" for small numbers. We'll think about this some more.

mheppler added a commit that referenced this issue Jul 19, 2019

@pdurbin pdurbin removed their assignment Jul 19, 2019

@djbrooke djbrooke removed this from IQSS Team Dev 💻 in IQSS/dataverse Jul 20, 2019

pdurbin added a commit that referenced this issue Jul 22, 2019

mheppler added a commit that referenced this issue Jul 22, 2019

mheppler added a commit that referenced this issue Jul 22, 2019

pdurbin added a commit that referenced this issue Jul 22, 2019

pdurbin added a commit that referenced this issue Jul 22, 2019

pdurbin added a commit that referenced this issue Jul 22, 2019

mheppler added a commit that referenced this issue Jul 24, 2019

mheppler added a commit that referenced this issue Jul 24, 2019

mheppler added a commit that referenced this issue Aug 1, 2019

mheppler added a commit that referenced this issue Aug 8, 2019

mheppler added a commit that referenced this issue Aug 9, 2019

@kcondon kcondon closed this in #6040 Aug 9, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
4 participants
You can’t perform that action at this time.