Tuesday, 20 August 2013

Using poisson family for log+1 counts in glm

Using poisson family for log+1 counts in glm

I'm running a GLM using counts as my response variable and would normally
use family=poisson. Yet I'm also running SAR models, which couldn't easily
handle my counts as there was such a small amount of variation between
them (high number of counts at very low numbers) so my supervisor
suggested I use the hack of log(counts)+1 as my new response variable.
Should I be using the family poisson?
The use of the family poisson will give more conservative results
(significance wise) when compared to the same model without poisson family
specified, but will obviously give me warnings as I have non integers.
Because of this (I assume) it wont give me an AIC either.
Any advice would be awesome!

Monday, 19 August 2013

How to get records in mysql where first letter equals 'X', when dealing with spanish characters?

How to get records in mysql where first letter equals 'X', when dealing
with spanish characters?

As an example:
select *
from recording as r
where left(r.title, 1) = 'p'
This picks all the recordings that start with the letter p.
But, the problem is that i'm dealing with a spanish table that contains
recordings like ¿Por qué? or «Por un amor» o even ¡Pon la mesa!, etc...
And that's just one example...
How do i get the recordings that start with a specific letter when i'm
dealing with spanish special characters like the one described above?
Do i need to create a separate column in the table, let's call it 'sort
name', and strip all of those special characters? Are they other
solutions, special functions that i'm not aware of in mysql?
Thanks

How to export an Outlook task view connected to a Sharepoint list?

How to export an Outlook task view connected to a Sharepoint list?

I'm exposing a Sharepoint list to Outlook 2010 via Sharepoint BCS as a
task list, and would like to export the view as documented in the
following link:
http://msdn.microsoft.com/en-us/library/ee819848(v=office.14).aspx
I don't see an option to export a view. Is it because this option isn't
available when working with data connected to Sharepoint?

qgetenv returns NULL

qgetenv returns NULL

I need to get the value of a environment variable in linux(UBUNTU). For
this purpose I am using "qgetenv" function with the environment variable
name. I can confirm that value of environment variable is set because when
I do echo $VARIABLE_NAME, it is perfectly printing the value of the
variable. This snippet of the code I am using:
QByteArray root = qgetenv("PAPARAZZI_HOME");
if (root.data()==NULL) {
cerr << "PAPARAZZI_HOME is not defined" << endl;
exit(0);
}
string pprzRoot = string(root.data());
and echo $PAPARAZZI_HOME prints following string:
"/home/manish/paprazzi-git/paparazzi/"

capslock strange behavior on my laptop

capslock strange behavior on my laptop

My problem is the following :
"alt" and "alt gr" won't work without "capslock" on ! So I keep switching
"capslock" on and off when I need those : ~#{[|`\^@]} really annoying when
programming !
and ctrl-alt-delete become capslock + ctrl-alt-delete + capslock ...
The really strange part is that I have the same problem with windows 7 and
opensuse 12.3 (double boot), and ubuntu 12.04 (live usb) !
Also I tried a wireless keyboard and it worked fine ! This would make me
think of an hardware problem. But how would it be possible ?
My laptop is an HP ProBook 4320s bios supposed to be up to date.

SQL JOIN Variable

SQL JOIN Variable

I have tables:
tasks
id
name
description
parent_id
parent_type
accounts
id
name
leads
id
name
My query that works looks
SELECT tasks.name,date_due, tasks.description, accounts.name FROM tasks
JOIN accounts
on tasks.parent_id = accounts.id
WHERE DATE(date_due) = DATE(NOW() + INTERVAL 1 DAY) AND
tasks.assigned_user_id=1
What I need is to make the accounts a variable - it can be either accounts
or leads, depends on the tasks.parent_type value.
Any tips how to achieve this?

Sunday, 18 August 2013

What word means centered about death?

What word means centered about death?

I'm writing an essay about Don DiLillo's novel White Noise, and would like
to explore Murray Jay Siskand's fascination with death. The particular
word I'm looking for means "death-centric", to fit in the topic sentence
"Furthermore, the consumerist society that envelops Siskind results in his
<word goes here> viewpoint of his surroundings."
Failing that, is there a way to rework this sentence as to allow for an
elegant focus on his death-centric viewpoint?