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

Adding plot with membership counts by month/year #75

Open
wants to merge 1 commit into
base: master
from

Conversation

@vsoch
Copy link
Member

commented Jul 29, 2019

This pull request will add a plot to the join page to show the growth of us-rse over time! Here is a quick snapshot:

image

How does it work?

The data itself is read from a simple csv file, memberCounts.csv, that is served from data. It's a file that includes month/year, count, and totals. We have it organized by month/year because the units specified here directly determine the scale of the Y axis for the plot, and we don't want it to be uneven (@cosden can comment on this because he pointed it out!) Here is the current data:

Date,Count,Total
"February, 2018",2,2
"March, 2018",1,3
"April, 2018",1,4
"May, 2018",1,5
"June, 2018",1,6
"July, 2018",0,6
"August, 2018",0,6
"September, 2018",0,6
"October, 2019",0,6
"November, 2018",3,9
"December, 2018",0,9
"January, 2019",1,10
"February, 2019",1,11
"March, 2019",9,20
"April, 2019",9,29
"May, 2019",17,46
"June, 2019",39,85
"July, 2019",49,134

Importantly, the data is programatically generated (but not downloaded to the file) in the Spreadsheet associated with the updated Google form, and historical data has been summarized and included, also by month, in the same format. I included both the historical raw data and the script to generate the counts so there is absolutely no doubt about how it was produced here: https://gist.github.com/vsoch/b86537e3b9171a2292e0587f20bd47fe

For the spreadsheet (admins of the organization have access) there is a second tab:

image

And the historical data generated from the gist above is highlighted in yellow at the top. Notice that the first column after the date is general counts, and the third column uses that counts column plus the cell above it to keep a running total.

image

Important July 2019 is a special case, because we have BOTH data generated from the new form, along with historical data. Thus, to generate the count, we have a formula PLUS the original count from the spreadsheet (45)

=COUNT(FILTER('Form Responses 1'!A2:A100000,YEAR('Form Responses 1'!A2:A100000)=YEAR(A19), MONTH('Form Responses 1'!A2:A100000)=MONTH(A19))) + 45

This means that all following cells have that same calculation, but without the +45, which serves to look in the previous sheet for entries in column A from row 1 through 100000, and count cells
that have the YEAR corresponding to the YEAR in the current sheet's AX (for example, 2019) and the Month in the same sheet's AX (for example July). The result of this calculation is the count of timestamps in the previous sheet that have any record in July of 2019.

=COUNT(FILTER('Form Responses 1'!A2:A100000,YEAR('Form Responses 1'!A2:A100000)=YEAR(A19), MONTH('Form Responses 1'!A2:A100000)=MONTH(A19))) + 45

And so, to update the data for the site, you can either export to csv (and replace the whole thing or just the recent months) or just copy paste and replace the spaces with commas. The export is nice because it preserves the commas in quotes for the dates.

Signed-off-by: Vanessa Sochat vsochat@stanford.edu

adding plot with membership counts by month/year
Signed-off-by: Vanessa Sochat <vsochat@stanford.edu>
@cosden

This comment has been minimized.

Copy link
Member

commented Aug 3, 2019

This looks terrific! And it seems easy to update. Once we get this merged I can do an update for the rest of July to make sure it works for me too.

One suggestion: I tried it out locally and while I think it looks a bit better the way you have it, I think I'd prefer to put the plot under the join button. The main purpose of that page (and it's an important one) is to have people join, and not to show off the membership plot. If a few people miss the plot so be it.

@danielskatz

This comment has been minimized.

Copy link
Collaborator

commented Aug 3, 2019

Should we document somewhere that these numbers are as of the end of the month?

@danielskatz

This comment has been minimized.

Copy link
Collaborator

commented Aug 3, 2019

Ok, nvm, it looks like this is daily counts with a script that takes the final count of the month for plotting.

@vsoch

This comment has been minimized.

Copy link
Member Author

commented Aug 3, 2019

@cosden don't forget that we have Circle previews so you don't need to do things locally!

https://145-120906408-gh.circle-artifacts.com/0/usrse.github.io/join/index.html

I disagree about the ordering - it's a relatively short page (graph, text, button) and it's a natural progression of the user's experience to see a picture, and then scroll down (heck less than 100 pixels) to see the massive join. That's the reason they came to the page - to click that join, so they are motivated to do that. If you look at most pages with a graphic and text, the graphic comes first. On the other hand, when you just move it up it looks off to me. I can't imagine that someone really would proactively click the join page to join, and then have a 300 something pixel graphic distract them to forget to scroll down a little more to see the massive green button :P

@vsoch

This comment has been minimized.

Copy link
Member Author

commented Aug 3, 2019

Here is a preview, which is not my preference. I would predict a significant number of people to not scroll (and miss the graph entirely).

image

@vsoch

This comment has been minimized.

Copy link
Member Author

commented Aug 3, 2019

There is also a natural progression to scroll to keep reading - the top of the page asks the viewer "Why should I join the US-RSE association? and the natural tendency is to find the answer :)

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