Mturk External Survey Code - validation

I am trying to link up Mturk to my external Website
I am using the external survey Hit on the GUI requester page
I know that I need to generate the code myself, but I do not know how the code is validated.
In what form or fashion do I, or the Amazon site validate this code? and how do I implement this.
For example: A person gets a code from my website, and pastes it into the box of their amazon hit on the amazon website. Who is that code validated by? and if amazon how to I tell them which codes have been generated?
Thanks in advance!

You would do it yourself. you will find the code that the worker enters on the HIT page in your results file. Than you compare the results file with the list of codes you generated, and approve the correct codes.

A method is described on my blog which is ideal for surveys with lots of participants. Basically, you export the data from both your survey and Mechanical Turk, then you put the code columns side-by-side for comparison, and then you use a formula that takes each row of one column of codes and performs a lookup in the other column of codes. For example, you could use a COUNTIF formula in Excel, which returns a 1 if there is a single match, and a 0 otherwise.

Related

Identify unique visitor redirected from Qualtrics

I'm trying to redirect respondents within a survey in Qualtrics to a webpage. On this webpage, they need to choose between a couple of options, and after it return to Qualtrics.
I know it is possible to generate an unique URL within qualtrics (e.g. example.com/test?UniqueID=999). However, how can I 'catch' this parameter together with the participant's response?
Thank you!
To "catch" a parameter in Qualtrics, you need to create an embedded data block in your survey flow and then create an embedded data field within that block with the same name (case-sensitive!) as the parameter. Instructions are available in the Qualtrics documentation here.
Please note that if you want to ensure that the parameter will be recorded for all responses, you should place the embedded data block first in your survey flow. (If it's placed after the question block(s), it will only be recorded for respondents who complete all the questions.)

What code should I add (and where) on my website to track events/identify users on my website using segment.com?

I want to configure segment.com properly on my site and use it to manage all other apps/tools. I already installed the segment javascript on my site and used it as the source. Now, I am pushing these to MixPanel, Facebook, Google Analytics, etc.
What code should I add if I want to track an event and/or identify a user?
For simplicity's sake, i have a landing page (site.com/landing-page) with a form. After a successful submission, it redirects to a thank you page (site.com/thank-you-page).
The default settings already track the page views, and are pushing that same event to the different tools (FB: PageView, MixPanel: Loaded a Page, etc).
But in this case, i want to track the event and capture the person's information. And i don't know what to code to add and where.
My research so far
According to this article:
The best way to track new users is in client-side javascript on the welcome page after they signup, below we’ll explain why.
So, based on that, I add the code to my thank you page. But where? Header like adding GA scripts? body tag? I can add it anywhere, but i don't know where.
Next is what code should I add?
The example from the same article above:
When a new visitor goes to their site that visitor is anonymous. As soon as the visitor connects their Facebook account, Rdio knows who they are and creates a user record.
As part of that new user record the person is assigned a userId. Let’s say the new userId is 12345. Rdio will then need to fire the following calls on the welcome page:
analytics.identify('12345',{ name:'Jake Peterson', email:'friends#segment.com'});
analytics.track('Account Created',{ authentication:'Facebook'})
This gives me two problems: track and identify.
Track Problem
I'll start with the track. Based on how I understood this, assuming the event name i want to be added is "Downloaded PDF" then I want to store the title of it as well. It should look like this, right?
<script>
analytics.track('Downloaded PDF', {
title: 'Awesome Title'
});
</script>
Am I correct to enclose them inside <script> tags?
The tracking of an event seems a bit easier to understand that the identify part. But would love to know if i got that part right.
Identify Problem
Here, i have two questions:
where does userId come from? Is it automatically generated? For example, inside my MixPanel account, i see them. Is that what i use?
How do i reference to the userId? or any of the other traits I want to track in my code?
Taking from the same example above:
analytics.identify('12345',{ name:'Jake Peterson', email:'friends#segment.com'});
If i add this exact code on my thank you page, every signup will be assigned those values: '12345', 'Jake Peterson', and 'friends#segment.com', right?
What code should I add to (1) assign them the right userId (2) and get the name and email traits from the form of the previous page.
Let's say i'm only collecting first name and email.
analytics.identify("userId"{ firstName:"firstName", email:"email"});
If I add this code to my thank you page, will it automatically assign the userId, firstName, email values of the form that was submitted? That's the part I don't understand. What code to add to dynamically push the correct data.
And i know i'm not even adding the Alias part for MixPanel yet, but i just want to understand this part and the rest (hopefully) will be easier to understand.

MiniProfilerEF view results without RenderIncludes()

Is there another way to view the profiling results of MiniProfiler (I'm specifically interested in EF5 version)?
Every tutorial that I've seen uses MiniProfiler.RenderIncludes(); but since my MVC app mostly returns JSON, that is not an option for me.
Is there a way to write results to file or something like that?
You can read and write results to just about anywhere by changing the MiniProfiler.Settings.Storage to a different IStorage implementation from the default (which stores to http cache). If you wanted to, this could store to and read from a file pretty easily (you would have to write your own custom implementation for that).
The files served by RenderIncludes are the html templates for displaying the results and the script to retrieve the results from the server and render them on the client (all found here). But you are by no means obliged to use this mechanism. If you want to write your own logic for retrieving and displaying results, you should base this off of the logic found in MiniProfilerHandler.GetSingleProfilerResult. This function roughly performs the following (putting in the siginificant steps for your purposes):
Gets Id of next results to retrieve (through MiniProfiler.Settings.Storage.List())
Retrieves the actual results (MiniProfiler.Settings.Storage.Load(id))
Marks the results as viewed so that they wont be retrieved again (MiniProfiler.Settings.Storage.SetViewed(user, id))
Converts these to ResultsJson and returns it
With access to MiniProfiler.Settings.Storage, you should be able to retrieve, serve and consume the profile results in any way that you want. And if you are interested in using the RenderIncludes engine but want to mess around with the html/js being served, you can provide your own custom ui templates that will replace the default behavior.

How to get Places Reference Key?

I have few lat,lng of some Google Places business which I want to search and get detailed information about that place.
I was looking at Place Detail search which require reference key of particular place page.
Here is what I am doing is.
Do Place search via api key for lat,lng
https://maps.googleapis.com/maps/api/place/nearbysearch/xml?location=lat,lng&radius=50&location=lat,lng&name=placenamesensor=false&key=my key
that returns exact place page result in xml and i grab ref key of that page.
then do call
https://maps.googleapis.com/maps/api/place/details/xml?reference=RefKey&sensor=false&key=MyKey
which gives output of particular business.
Now question is on 1st step to get ref key of business what if I dont know name but just know lat,lng and wish to grab ref key of that page. What query I have to fire to reduce api calls limit?
You can find it here:
I believe this is what you are looking for
https://developers.google.com/maps/documentation/javascript/places
you need to work with places api and implement the the typeahead feature
https://developers.google.com/maps/documentation/javascript/places#TextSearchRequests

Ruby on Rails using tabs

everyone!
At first, I made a single form with large amount of elements: text fields, text areas and so on. When I had got the form ready, I understood that it is not so user-friendly to have such a large form to be filled-in in a row. I don't want to use the "step" system (step 1 -> step 2 -> ... -> step n), because I want for the end-user to be able to have this form filled in any order (+ User would be able to see beforehead what forms he would need to fill), so I divided the form into the several tabs.
The idea is following: once user has filled the form in some tab, he hits the "Save" button and proceeds to the next one (in arbitrary order of his choice).
The thing I wanted to know - what would be the best approach to store the intermediate data ? Should I have some hidden input for each of the tab forms with tab-id to be passed to the model, so that at each 'step' only tab relevant data was validated and stored in DB. Or, maybe, I should have a session[:object] that would contain the current object and at the very end I would store it in DB and erase from the session.
Can this idea be realised ?
Thanks in advance! :)
there's a gem called wicked, it allows you create wizards in a very simple way, check it out
I'm not a ruby ninja, but in other languages (like php) we usually use sessions to do this. Why not to do this on rails?
Also you can consider creating a table for "temporary storage rows" in addition of using sessions, so every time you change the page you could save the data to that table and, at the end, save them all to your main tables.
This is useful if you usually loose your session... you can related the temporary storage rows with the user and if he looses the session, you can restore his uncompleted forms from your database.
You could simply go the Railscasts 217 - Multistep form approach, which works fine.
However, this may not suit you as you may only store the data AFTER you have everything collected, and not step by step.
Another solution - as you mentioned - would be using e.g. jQuery tabs to create your form steps and building a little validation via AJAX / backbone.js before storing the actual record with all its data.

Resources