Tag Archives: coding

Generating Function Library Quizzes (#TeachersCoding)

I've required my IB classes in the past two years to be able to draw some standard functions from memory as part of our function families unit. Creating quizzes for this has been a hassle since I've manually had to build these using Word or LibreOffice. I greatly dislike formatting things using either software package.

I decided this week that creating these quizzes using HTML seemed like a perfect application of my developing React skills. Here's the result:

screen-shot-2016-11-04-at-6-54-23-pm

The order of the functions randomly generates on each page load, which makes it easy to generate new versions. I've been able to export these as PDF files and then send them right to the printer.

You can access the code here on CodePen:

See the Pen FunctionLibraryQuiz by Evan Weinberg (@emwdx) on CodePen.0

Feel free to use this or modify to fit your needs.

Two Lane Road and Collaborative Data Collection

I love doing three act problems. This fact should surprise nobody that regularly reads my blog.

In tasks that involve prediction or measurement from a range of sources, I see lots of tables of values made by students that stay in the notebook. I have always wanted to get that data in the hands of the rest of the students to use, or not use, as they see fit. In one of my previous iterations, I pasted the data into a shared Google spreadsheet that students could then paste into a Desmos graph, again, if they felt doing so would be helpful. This was incredibly rich source of material for conversations between students. Still, that extra step of having to paste from one collaborative document (Google) to a non-collaborative one (Desmos Calculator) was one more step than I felt was needed.

Of course, you're now screaming at the screen. "Calling out Desmos for being non-collaborative is entirely off base, Evan" , you say. I agree to an extent. Their own activities share data collected by individual students, and on the teacher side, the Activity Builder does the same thing for letting teachers see student data all in one place. They do this incredibly well. Students also get to see each others answers when teachers let them. What doesn't happen right now is students seeing each other's graphs, tables, and lists of expressions.

This, along with a desire to play with the Desmos API, is why I created DataTogether (Github repository here), a hacky way to make Desmos data collaborative. The page is written in React, and uses Firebase to do the realtime data connection.

Dan Meyer tweeted shortly after that these changes might be somewhere in the pipeline already:

This is probably why I may not be adding a lot of code comments to my code in the near future.

I did my Two Lane Road 3-act with a small group of students this morning on account of tenth graders being out for the PSAT. After the standard Act 1 conversation, and a really great conversation about agreements between groups on collecting data from the video, the students began collecting data on the red and blue cars.

The students were efficiently able to collect data together on separate computers after profuse apologies for the limitations of my code:

screen-shot-2016-11-02-at-9-45-38-am

screen-shot-2016-11-02-at-9-44-37-am

I then had each student use the tools within Desmos to construct a linear model from the data. The fact that two computers were looking at the same data, but in different Desmos windows, paid significant dividends when two students on the same team created their models in different ways. One student made a regression. Another created a line that went through one set of points perfectly, but missed another. Math class conversation gold right there.

I exported both of their data through the console (code shown below) and pasted it into Desmos. I then put together a simulation of the red and blue car so that the teams could see what their car looked like in simulation.

screen-shot-2016-11-02-at-9-56-22-am

You can check out the Desmos graph here.

This allowed us to make a prediction directly off of their models that looked like the original video.

We ran out of time in the end to do much more than sharing predictions and watching the third act, but I'm pretty pleased with how things went overall. My paper handouts with three printed color frames of the video went unused. I think


A big shout-out of thanks to everyone for helping test the data collection tool I shared earlier.

Here's a screenshot of our age vs. teaching years data:
screen-shot-2016-11-02-at-10-00-41-am

The data can be downloaded from the DataTogether page, loading data set 3DR9, and then by going to the console and entering the code below:

ptString = "";
myComponent.state.groupData.forEach(function(pt){ptString=ptString+pt.x+" \t "+pt.y+" \n "});

This string can then be pasted right into the Desmos expression list if you want to play with it.

#TeachersCoding: Building an Image Downloader for WODB

If you read my blog regularly, you know how I feel about using technology to manage repetitive tasks. It's intimidating to learn to code without purpose. Seeing how code can be used in the context of making a teacher's job easier is a much more direct motivation for learning to do it yourself.

Here's my next installment in the TeachersCoding series. In four minutes, you get the basic steps and tools for putting together a Python program that will download images from Mary Bourassa's excellent Which One Doesn't Belong website . All that's missing is you going through the steps yourself:

This program doesn't download all of the images from the website - that's a task for you to figure out and do on your own. It doesn't take much. My goal is to have more teachers get hooked by the thrill of seeing code they create do something that is practical and adaptable to their own purposes. We need to grow our ranks.

Share any issues you find in the comments below. I'm excited to get this out there and see what you do with it.

Relevant links:

Code for Teachers: What do you want to learn to build?

A conversation with Dan Anderson(@dandersod) this morning has pushed me to revisit a coding for teachers concept that I've nudged forward before, but haven't made happen to my liking yet. There's an amazing variety of coding materials and tutorials out there, but few that I've seen take the approach of helping teachers build immediately useful tools to improve their workflow.

 To be done right, this must acknowledge the fact that this valid sentiment is out there:

@cheesemonkeysf: @dandersod @emwdx @dcox21 But are you prepared for… the "coding-impaired"?

As any person that has dabbled in programming knows, there's always a non-trivial period of frustration and bug hunting that comes with writing code. This discomfort is a part of learning any new skill, of course. It's also easy to say that you aren't a code person, just as someone can say that he or she isn't a math person. What pushes us (and our students) through this label to learn anyway?

  • Minimal hand-waving about how it 'just works'
  • Experiences that demonstrate the power of a growth mindset
  • Concrete ideas first, abstraction later
  • Building the need for better tools
  • Maybe the most important: having the right people at your side

I want to work to make this happen. Consider this a pile of rocks marking the beginning of that trail.
How do we start? I see this as an opportunity to use computational thinking as a way to improve what we do in the classroom. This project should be built on improving workflow, with the design constraint that it needs to be accessible and as useful as possible. I also want to use a range of languages and structures - block programming, spreadsheet, Automator, everything is fair game.

I want to first crowdsource a list of tools that would be useful to learn to build. Let's not limit ourselves to things that are easy at this point - let's see what the community wants first. I've posted a document here:

What Do You Want To Learn To Build?

Go there and share your ideas. I don't want to wait any longer to start talking about what this could be.

    Coding IS a super(edu)power

    I've been really impressed by the Dan Meyer/Dave Major collaboration. If you don't know what I'm talking about, you need to click on that link immediately. Seeing both Dan and Dave post on their respective blogs about the thought and rationale that goes into these activities is like a masters class in pedagogy, digital media, and user design.

    The common thread that I really like about these tools is the clean and minimalist way they pose an idea, encourage a bit of play and intuition, and then get out of the way. Dan has talked about these ideas philosophically for a while, and seeing Dave make these happen is really exciting. They talk about this being the future of textbooks, but I am willing to wager that textbooks will get fidgety at displaying a task to a user atop a blank white screen. The trend has been so far in the other direction that I am skeptical, but I am hopeful that they will start to listen. These exercises are like a visit to the Museum of Modern Art. Textbooks and online learning otherwise tends to look either like a visit to Chuck-E-Cheese or the town library, over-thinking or under-thinking the power of aesthetics to creating a learning environment that is stimulating enough, but not distracting.

    Being a committed Twitter follower, I of course interrupted their workflow with suggestions. I was looking for an easy way to collect student responses to a question along the lines of Activeprompt, but for tasks that are not about finding a location. I had posed a question to my Geometry class and was really excited about greasing the rails for gathering student responses and putting them in one place. This is the same idea as what Dan/Dave had done, but with a bit less of a framework pushing it in a direction.

    Dave's suggestion was, well, intimidating:

    Screen Shot 2013-03-21 at 4.48.19 PM

    I had been playing around with web2py, Django, Laravel, and other template frameworks that said they would make things easy for me, but it just didn't click how they would do this. I have done lots of small Python projects, but the prospect of making a website seemed downright unlikely. I spent three hours putting together this gem using the CSS I had learned from CodeAcademy:
    Screen Shot 2013-03-21 at 4.56.54 PM

    I was not proud of this, but it was the best I thought I could do.

    Through the power of Twitter, I was able to actually have a conversation with Dave and learn how he put his own work together. He uses frameworks such as Raphael.js and Sinatra in a way that does just enough to achieve the design goal. I learned that he wasn't doing everything from scratch. He took what he needed from what he knew about these different tools and constructing precisely what he envisioned for his application. I prefer Python to Ruby because, well, I don't know Ruby. I found Bottle which works beautifully as a small and simple set of tools for building a web application in Python, just as Dave had done with his tools.

    Using Bottle and continuing to learn how it works, I made this yesterday.
    BFwz3k5CQAEE2ts.png-large

    I shared it with Dave, and he revealed another of his design secrets: Bootstrap. Again, dumbstruck by the fact this sort of tool exists, but also that I hadn't considered that it might. This led me to clean up my previous submission and reconsider what might be possible. With a bit more tinkering, I turned this into what I had envisioned: a flexible tool for collecting and sharing student responses to a question
    Screen Shot 2013-03-21 at 5.12.14 PM

    I was just tickled pink. Dave had shown me his prototype for what he made in response to my prompt - I was blown away by it, as with the rest of his work. Today, however, I proudly used my web app with two of my classes and was happy to see that it worked as designed.

    The point behind writing about this is not to brag about my abilities - I don't believe there is anything to brag about here. Learning to code has gotten a good mix of press lately on both the positive and negative side. It is not necessarily something to be learned on its own, for its own sake.

    I do want to emphasize the following:

    • My comfort with coding is developed enough at this point that I could take my idea for how to do something in the classroom using programming and piece it together so that it could work. I got to this point by messing around and leaving failed projects and broken code behind. This is how I learn, and it has not been a straight line journey.
    • If I was not in the classroom on a regular basis, I doubt I would have these ideas for what I could do with coding if I had the time to focus on it completely. In other words, if I ditched the classroom to code full time (which I am not planning to do) I would run out of things to code.
    • Twitter and the internet have been essential to my figuring out how to do this. Chatting virtually with Dave, as an example, was how I learned there was a better way than the approach I was taking. There are no other people in my real world circles who would have introduced me to the tools that I've learned about from Dave and other people in the twitterverse. Face to face contact is important, but it's even better getting virtual face time with people that have the expertise and experience to do the things I want to learn to do.
    • I have been writing code and learning to code from the perspective of trying to do a specific and well defined task. This is probably the most effective and authentic learning situation around. We should be looking for ways to get students to experience this same process, but not by pushing coding for its own sake. As with any technology, the use needs to be defined and demanded by the task.
    • The really big innovations in ed-tech will come from within because that's where the problems are experienced by real people every day. Outsiders might visit and see a way to help based on a quick scan of what they perceive as a need. I'm not saying outsiders won't or can't generate good ideas or resources. I just think that tools need to be designed with the users in mind. The best way to do this is to give teachers the time, resources, and the support to build those tools themselves if they want to learn how.

    You can check out my code at Github here. Let me know if you want to give it a shot or if you have suggestions. This experiment is far from over.