Creating a new column based on Flag or Star

93 views
Skip to first unread message

John David Smith

unread,
May 24, 2014, 7:47:44 PM5/24/14
to openr...@googlegroups.com
Every time Open Refine saves my butt, I think I should give back.  I thought of adding a use case for creating a new column based on the value of a row's flag or star.  Then I wondered whether there's an obvious or ready-made way to do that.  I'd hate adding a bad strategy to the use case list.  

My solution was to facet on the Flag or Star that I'd previously created.  Then I selected "True" or "False" and created a new column based on a column that always had a value and just put "yes" or something in the value box.  Seems kind of ugly, but it worked.  My question: isn't there a better way?

By the way, does anybody else have trouble searching a wiki in GitHub?  Like, how would I find "startsWith" in the user documentation (wiki)?  When I put that in the search box it returns source code, not documentation.

Thanks!

John 

Thad Guidry

unread,
May 24, 2014, 9:37:04 PM5/24/14
to openr...@googlegroups.com
Hmm, I don't think there is a better way, John...that's what I do also when needed.

To search wiki's on Github, most folks just install github-wiki-search, which is available for most browsers: https://github.com/linyows/github-wiki-search
 


--
You received this message because you are subscribed to the Google Groups "OpenRefine" group.
To unsubscribe from this group and stop receiving emails from it, send an email to openrefine+...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.



--

fabio.tacchelli

unread,
May 26, 2014, 11:00:37 AM5/26/14
to openr...@googlegroups.com
You could use an IF statement with row.starred or row.flagged, for example: if(row.starred, "yes", "no")
Should be slightly faster than faceting everytime just to create the new column.


Fabio

Martin Magdinier

unread,
May 26, 2014, 11:30:20 PM5/26/14
to openrefine

On www.openrefine.org there is Google custom search to search the user doc and various tutorials.

Thanks Thad for the link.

--

John David Smith

unread,
May 27, 2014, 11:29:10 AM5/27/14
to openr...@googlegroups.com

Thanks Thad, but I just searched for “startsWith” and got “No Results”.  On the other hand searching for “star” does take me to one or two relevant pages (I think there should be others, but I can’t quite put my finger on them).

 

And thanks Fabio.  Adding your solution to the wiki now.

 

John

____________________

* John David Smith ~ Voice: 503.963.8229 ~ Skype & Twitter: smithjd http://gplus.to/smithjd

* Portland, Oregon, USA http://www.learningAlliances.net

* Society does contain profundity and sacredness." -- Chögyam Trungpa, Rinpoche

--
You received this message because you are subscribed to a topic in the Google Groups "OpenRefine" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/openrefine/ruEOu1rZqoQ/unsubscribe.
To unsubscribe from this group and all its topics, send an email to openrefine+...@googlegroups.com.

Thad Guidry

unread,
May 27, 2014, 11:38:36 AM5/27/14
to openr...@googlegroups.com
John,

Did you type into the right input box ?  See my yellow highlights in the following PNG's :
-- 

John David Smith

unread,
May 27, 2014, 2:34:34 PM5/27/14
to openr...@googlegroups.com

Well, I don’t see that search box on this page!

 

https://github.com/OpenRefine/OpenRefine/wiki

 

Here’s what it looks like on my end:

 

 

John

____________________

* John David Smith ~ Voice: 503.963.8229 ~ Skype & Twitter: smithjd http://gplus.to/smithjd

* Portland, Oregon, USA http://www.learningAlliances.net

* Society does contain profundity and sacredness." -- Chögyam Trungpa, Rinpoche

 

image001.png

Thad Guidry

unread,
May 27, 2014, 9:31:36 PM5/27/14
to openr...@googlegroups.com
Did you install the Google Chrome extension for GitHub-Wiki-Search ?


(and then restart Chrome for the change to take effect ?)

John David Smith

unread,
May 28, 2014, 6:34:44 PM5/28/14
to openr...@googlegroups.com

That makes a huge difference, Thad!  Very handy.

 

I added a note to that effect here: https://github.com/OpenRefine/OpenRefine/wiki/Documentation-For-Users

image001.png

Tom Morris

unread,
May 28, 2014, 9:11:04 PM5/28/14
to openr...@googlegroups.com

Perhaps a good tip to add to a prominent place in the wiki?

Tom

Thad Guidry

unread,
May 28, 2014, 10:05:44 PM5/28/14
to openr...@googlegroups.com

Tom Morris

unread,
May 28, 2014, 11:18:19 PM5/28/14
to openr...@googlegroups.com
Thanks, Thad!  The power of the community at work...
Reply all
Reply to author
Forward
0 new messages