Hello!
managed to sort it out, pasting below the proper one if something fyi!
DISP1
AFTER ENTRY
IF (DRUG1="EFV") and (DOS1=600) and (DISP1>28) and (DISP1<101) THEN
DAILYD1=1
GOTO DRUG2
ENDIF
IF (DRUG1="EFV") and (DOS1=200) and (DISP1>118) and (DISP1<181) THEN
DAILYD1=4
GOTO DRUG2
ENDIF
IF (DRUG1="EFV") and (DOS1=200) and (DISP1>88) and (DISP1<110) THEN
DAILYD1=3
GOTO DRUG2
ENDIF
END
END
best regards
ziad
On Tue, Jun 10, 2008 at 12:08 PM, Ziad El-Khatib <ziad.khatib(a)gmail.com> wrote:
> Hi again,
> another question inline with previous query i posted last month, to
> have different -if..then- conditions (pasted below), when i test it,
> it does not write anything under DAILYD1 cell, as instructed below,
> any tips?
>
> DISP1
> AFTER ENTRY
> IF (DRUG1="EFV" & DOS1=600 & DISP1>29 & DISP1<101) THEN
> DAILYD1=1
> ELSE
> IF (DRUG1="EFV" & DOS1=200 & DISP1>119 & DISP1<181) THEN
> DAILYD1=4
> ELSE
> IF (DRUG1="EFV" & DOS1=200 & DISP1>89 & DISP1<110) THEN
> DAILYD1=3
> GOTO DRUG2
> ENDIF
> ENDIF
> ENDIF
> END
> END
>
>
>
>
>
> Thank you and best regards
> ziad
>
>
> On Thu, May 29, 2008 at 10:03 AM,
> <epidata-list-request(a)lists.umanitoba.ca> wrote:
>> Send EpiData-list mailing list submissions to
>> epidata-list(a)lists.umanitoba.ca
>>
>> To subscribe or unsubscribe via the World Wide Web, visit
>> http://lists.umanitoba.ca/mailman/listinfo/epidata-list
>> or, via email, send a message with subject or body 'help' to
>> epidata-list-request(a)lists.umanitoba.ca
>>
>> You can reach the person managing the list at
>> epidata-list-owner(a)lists.umanitoba.ca
>>
>> When replying, please edit your Subject line so it is more specific
>> than "Re: Contents of EpiData-list digest..."
>>
>> EpiData-list mailing list
>> ___________________________________
>>
>> Today's Topics:
>>
>> 1. Re: If..then (epidata-list(a)lists.umanitoba.ca)
>> 2. re: If..then (epidata-list(a)lists.umanitoba.ca)
>> 3. Re: EpiData-list Digest, Vol 55, Issue 19 Missing values is
>> not NA (epidata-list(a)lists.umanitoba.ca)
>>
>>
>> ---------- Forwarded message ----------
>> From: epidata-list(a)lists.umanitoba.ca
>> To: epidata-list(a)lists.umanitoba.ca
>> Date: Wed, 28 May 2008 20:33:07 +0200
>> Subject: Re: [EpiData-list] If..then
>> Perhaps:
>>
>> AFTER ENTRY
>> IF v64="NA" THEN
>> V65=9
>> V66=9
>> goto V67
>> ENDIF
>> END
>>
>>
>> Regards,
>>
>> Hans
>>
>>
>> epidata-list(a)lists.umanitoba.ca wrote:
>>>
>>> Hi,
>>> might be easy question, i am trying to write condition under check
>>> file to write value of 9 in 2 places if one cell equal to NA (code
>>> below), it does not work (and no error message), any tips?
>>>
>>>
>>>
>>> Thank you in advance
>>> best regards
>>> ziad
>>>
>>>
>>
>> --
>> Hans L Rieder, MD, MPH
>> Jetzikofenstr. 12
>> 3038 Kirchlindach
>> Switzerland
>>
>> Tel: +41 31 829 4577
>> Mob: +41 79 321 9122
>> Web: http://www.tbrieder.org
>>
>>
>>
>>
>>
>> ---------- Forwarded message ----------
>> From: epidata-list(a)lists.umanitoba.ca
>> To: epidata-list(a)lists.umanitoba.ca
>> Date: Wed, 28 May 2008 23:33:56 +0200
>> Subject: [EpiData-list] re: If..then
>> Just split in three lines:
>>
>> after entry
>> IF v64=NA THEN
>> LET V65=9
>> V66=9
>> goto V67
>> ENDIF
>>
>>
>> regards
>> Jens Lauritsen
>> EpiData Association
>>
>>
>>
>> ---------- Forwarded message ----------
>> From: epidata-list(a)lists.umanitoba.ca
>> To: epidata-list(a)lists.umanitoba.ca
>> Date: Thu, 29 May 2008 09:05:47 -0300
>> Subject: [EpiData-list] Re: EpiData-list Digest, Vol 55, Issue 19 Missing values is not NA
>> Dear friend Ziad,
>>
>> NA is common expression to identify missing values. If you are working with
>> R or S-Plus then NA is NA. That means that all functions or commands that
>> you want to specify NA, the expression is also NA. However, in Stata or
>> Epidata entry the NAs are epecified by dots (.) and sometimes by empty
>> quotes (" ") depending if the variable of interest is formated as numeric or
>> text. So, my guess is that your check command will work fine if do like
>> this...
>>
>> AFTER ENTRY
>> IF v64=. THEN
>> LET V65=9 & V66=9 & goto V67
>> ENDIF
>> END
>>
>> Best regards,
>> Pedro Emmanuel
>>
>>
>>
>>> Today's Topics:
>>>
>>> 1. If..then (epidata-list(a)lists.umanitoba.ca)
>>>
>>>
>>> ----------------------------------------------------------------------
>>>
>>> Message: 1
>>> Date: Wed, 28 May 2008 08:47:34 -0700
>>> From: epidata-list(a)lists.umanitoba.ca
>>> Subject: [EpiData-list] If..then
>>> To: epidata-list(a)lists.umanitoba.ca
>>> Message-ID:
>>> <897a5cf60805280847u3b99c66ak6f49e3855b879141(a)mail.gmail.com>
>>> Content-Type: text/plain; charset=ISO-8859-1
>>>
>>> Hi,
>>> might be easy question, i am trying to write condition under check
>>> file to write value of 9 in 2 places if one cell equal to NA (code
>>> below), it does not work (and no error message), any tips?
>>>
>>> AFTER ENTRY
>>> IF v64=NA THEN
>>> LET V65=9 & V66=9 & goto V67
>>> ENDIF
>>>
>>>
>>> Thank you in advance
>>> best regards
>>> ziad
>>>
>>>
>>> ------------------------------
>>>
>>> ________________________________________
>>> EpiData-list(a)lists.umanitoba.ca
>>> http://lists.umanitoba.ca/mailman/listinfo/epidata-list
>>>
>>>
>>> End of EpiData-list Digest, Vol 55, Issue 19
>>> ********************************************
>>>
>>
>>
>> ________________________________________
>> EpiData-list(a)lists.umanitoba.ca
>> http://lists.umanitoba.ca/mailman/listinfo/epidata-list
>>
>>
>
Hi again,
another question inline with previous query i posted last month, to
have different -if..then- conditions (pasted below), when i test it,
it does not write anything under DAILYD1 cell, as instructed below,
any tips?
DISP1
AFTER ENTRY
IF (DRUG1="EFV" & DOS1=600 & DISP1>29 & DISP1<101) THEN
DAILYD1=1
ELSE
IF (DRUG1="EFV" & DOS1=200 & DISP1>119 & DISP1<181) THEN
DAILYD1=4
ELSE
IF (DRUG1="EFV" & DOS1=200 & DISP1>89 & DISP1<110) THEN
DAILYD1=3
GOTO DRUG2
ENDIF
ENDIF
ENDIF
END
END
Thank you and best regards
ziad
On Thu, May 29, 2008 at 10:03 AM,
<epidata-list-request(a)lists.umanitoba.ca> wrote:
> Send EpiData-list mailing list submissions to
> epidata-list(a)lists.umanitoba.ca
>
> To subscribe or unsubscribe via the World Wide Web, visit
> http://lists.umanitoba.ca/mailman/listinfo/epidata-list
> or, via email, send a message with subject or body 'help' to
> epidata-list-request(a)lists.umanitoba.ca
>
> You can reach the person managing the list at
> epidata-list-owner(a)lists.umanitoba.ca
>
> When replying, please edit your Subject line so it is more specific
> than "Re: Contents of EpiData-list digest..."
>
> EpiData-list mailing list
> ___________________________________
>
> Today's Topics:
>
> 1. Re: If..then (epidata-list(a)lists.umanitoba.ca)
> 2. re: If..then (epidata-list(a)lists.umanitoba.ca)
> 3. Re: EpiData-list Digest, Vol 55, Issue 19 Missing values is
> not NA (epidata-list(a)lists.umanitoba.ca)
>
>
> ---------- Forwarded message ----------
> From: epidata-list(a)lists.umanitoba.ca
> To: epidata-list(a)lists.umanitoba.ca
> Date: Wed, 28 May 2008 20:33:07 +0200
> Subject: Re: [EpiData-list] If..then
> Perhaps:
>
> AFTER ENTRY
> IF v64="NA" THEN
> V65=9
> V66=9
> goto V67
> ENDIF
> END
>
>
> Regards,
>
> Hans
>
>
> epidata-list(a)lists.umanitoba.ca wrote:
>>
>> Hi,
>> might be easy question, i am trying to write condition under check
>> file to write value of 9 in 2 places if one cell equal to NA (code
>> below), it does not work (and no error message), any tips?
>>
>>
>>
>> Thank you in advance
>> best regards
>> ziad
>>
>>
>
> --
> Hans L Rieder, MD, MPH
> Jetzikofenstr. 12
> 3038 Kirchlindach
> Switzerland
>
> Tel: +41 31 829 4577
> Mob: +41 79 321 9122
> Web: http://www.tbrieder.org
>
>
>
>
>
> ---------- Forwarded message ----------
> From: epidata-list(a)lists.umanitoba.ca
> To: epidata-list(a)lists.umanitoba.ca
> Date: Wed, 28 May 2008 23:33:56 +0200
> Subject: [EpiData-list] re: If..then
> Just split in three lines:
>
> after entry
> IF v64=NA THEN
> LET V65=9
> V66=9
> goto V67
> ENDIF
>
>
> regards
> Jens Lauritsen
> EpiData Association
>
>
>
> ---------- Forwarded message ----------
> From: epidata-list(a)lists.umanitoba.ca
> To: epidata-list(a)lists.umanitoba.ca
> Date: Thu, 29 May 2008 09:05:47 -0300
> Subject: [EpiData-list] Re: EpiData-list Digest, Vol 55, Issue 19 Missing values is not NA
> Dear friend Ziad,
>
> NA is common expression to identify missing values. If you are working with
> R or S-Plus then NA is NA. That means that all functions or commands that
> you want to specify NA, the expression is also NA. However, in Stata or
> Epidata entry the NAs are epecified by dots (.) and sometimes by empty
> quotes (" ") depending if the variable of interest is formated as numeric or
> text. So, my guess is that your check command will work fine if do like
> this...
>
> AFTER ENTRY
> IF v64=. THEN
> LET V65=9 & V66=9 & goto V67
> ENDIF
> END
>
> Best regards,
> Pedro Emmanuel
>
>
>
>> Today's Topics:
>>
>> 1. If..then (epidata-list(a)lists.umanitoba.ca)
>>
>>
>> ----------------------------------------------------------------------
>>
>> Message: 1
>> Date: Wed, 28 May 2008 08:47:34 -0700
>> From: epidata-list(a)lists.umanitoba.ca
>> Subject: [EpiData-list] If..then
>> To: epidata-list(a)lists.umanitoba.ca
>> Message-ID:
>> <897a5cf60805280847u3b99c66ak6f49e3855b879141(a)mail.gmail.com>
>> Content-Type: text/plain; charset=ISO-8859-1
>>
>> Hi,
>> might be easy question, i am trying to write condition under check
>> file to write value of 9 in 2 places if one cell equal to NA (code
>> below), it does not work (and no error message), any tips?
>>
>> AFTER ENTRY
>> IF v64=NA THEN
>> LET V65=9 & V66=9 & goto V67
>> ENDIF
>>
>>
>> Thank you in advance
>> best regards
>> ziad
>>
>>
>> ------------------------------
>>
>> ________________________________________
>> EpiData-list(a)lists.umanitoba.ca
>> http://lists.umanitoba.ca/mailman/listinfo/epidata-list
>>
>>
>> End of EpiData-list Digest, Vol 55, Issue 19
>> ********************************************
>>
>
>
> ________________________________________
> EpiData-list(a)lists.umanitoba.ca
> http://lists.umanitoba.ca/mailman/listinfo/epidata-list
>
>
Hi Jamie
Sorry I sent the message without finishing my section on multiple data sets.
Working with Multiple data sets in Epidata Analysis
What I was going to say was our first attempt at working with several copies of an outbreak dataset had been sucessful. This was a timing thing - we wanted to get the data in more quickly. We had already entered 150 records when we decided to use another data entry person, but that was Ok the process still worked.
Our steps were
1. Created a file and entered records (outbreak1)
2. Used Tools copy structure to create a new file (outbreak 2)
3. Entered records in both outbreak 1 and outbreak 2
4. Used Data in/out then Append/merge option B to create a new file outbreak_final, that was outbreak1 and outbreak 2 combined.
What was good about this was that it was easy, and I also really liked the option to copy the check file we had set up for the first file to use with the new file when you copied the structure.
The only thing I didn't like so much was we ended up with a duplicate ID which we wouldn't get with an autoID (which we usually use for our ID field) but I used a number field rather than AutoID this time as I thought it would be a problem with the merge to have auto ID.
Using Multiple data sets in Epidata Analysis - READ and multiple data sets
Could you explain a bit more about how to do this. When I try and READ more than one data set it says "no data will be lost close first". Then - what does the SAVEDATA do - create a new file like MERGE does? Which do you recommend to combine data - Merging in Epidata entry or in Analysis.
Using Epidata analysis in a field epidemilogy course
I'm very interested in how you use Epidata Analysis in your field epidemiology course . Would I be able to find out a bit more about this from you - perhaps off the list to avoid taking up too much time on this topic? As I am involved in teaching courses using epidata/epi info to support field epi I am very interested in what you cover in your courses but realise others may not have the same interest
Many thanks
Christine
For multiple data sets (we do this every year in our Field Epidemiology
Course), you can use Merge in EpiData Entry or just READ multiple data
sets on one line in Analysis and then SAVEDATA.
Jamie
Christine wrote:
> I really like the outbreak analysis feature but on my wish list would be
> 1. for 'outbreak analysis' to be an option in one of the menus somewhere. I only knew about this feature through someone mentioning it on the list and I had to search through the docuentation to find it. Maybe this was what the 'attack rate plus RR' option was but I could not seem to select this - it stayed greyed out
Christine Roseveare
Analyst
Regional Public Health
570 9194
027 495 9671
--
The information contained in this email and
any attachments is confidential and may be
legally privileged. If you have received this
message in error, please notify the sender
immediately and remove all copies of the message,
including any attachments. Any views or
opinions expressed in this email (unless
otherwise stated) may not represent those of
Hutt Valley DHB.
Thank you.
** Disclaimer added by HVDHB **
Hi,
might be easy question, i am trying to write condition under check
file to write value of 9 in 2 places if one cell equal to NA (code
below), it does not work (and no error message), any tips?
AFTER ENTRY
IF v64=NA THEN
LET V65=9 & V66=9 & goto V67
ENDIF
Thank you in advance
best regards
ziad
Dear Christine
We do have notes (although different trainers have different notes to
reflect their own style). If you wish we can discuss further off-list
(e-mail neville.verlander(a)hpa.org.uk).
Regards,
Neville
------------------------------------------------------------------------
------------------------------------------------------------------------
------------------------------------------------------------------------
-----------------------------
Neville Verlander
Statistics Unit
Statistics, Modelling and Bioinformatics Department
Health Protection Agency Centre for Infections
61 Colindale Avenue
London
NW9 5EQ
Tel: (direct) (+44) (0)208 3277426
Fax: (+44) (0)208 200 7868
-----------------------------------------
**************************************************************************
The information contained in the EMail and any attachments is
confidential and intended solely and for the attention and use of
the named addressee(s). It may not be disclosed to any other person
without the express authority of the HPA, or the intended
recipient, or both. If you are not the intended recipient, you must
not disclose, copy, distribute or retain this message or any part
of it. This footnote also confirms that this EMail has been swept
for computer viruses, but please re-sweep any attachments before
opening or saving. HTTP://www.HPA.org.uk
**************************************************************************
Hi Alistair
Thank you for that. I found a copy of your training manual for using Epidata/Epi Info for analysing outbreaks on the web and think it is excellent.
Yes it is an interesting question about whether to change to Epidata Analysis for outbreak analysis. Like you I teach courses in using Epidata/Epiinfo and am interested in it from an ease of teaching/ease of use perspective as well as for my own use.
For my own use I am pretty sure I will change to Epidata analysis. We just had another small outbreak come up at the same time as the one I have been writing to the list about and my colleague wanted the data analysed in a hurry. Data had been entered in a questionnaire that was based on our standard epidata master one, just as the large outbreak was. I copied the programme I had written and saved for the large outbreak in Epidata analysis - made a couple of small changes - and was able to print out a symptoms profile, Epicurv graphs and two full attack rate tables - one with the outcome sick and one for the outcome of case (the case definition was created as part of the programme) for the 25 foods of interest less than 15 minutes. I thought that was pretty good.
For my training courses though I am not so sure. A large group coming to these are field staff who are new and/or infrequent users of any outbreak analysis software. At the moment my instinct is that although Epidata Analysis does things more quickly and has some great features- especially the attack rate tables which are brilliant - I think Epi info is easier for these new or infrequent users to understand.
I am thinking I may see if their is interest in me developing a one day course to introduce Epidata Analysis to people in public health units who are likely to take on a regular role analysing outbreaks, and stick with my current Epi info course for the wider group who want a very basic knowledge - so that it an emergency they could get out the manual and follow the instructions if the main person is away. I am interested to see though that the Health Protection Agency in the UK is offering both beginning and advanced one day courses for in Epidata Entry/Epidata Analysis. I saw the course outlines on the web http://www.hpa.nhs.uk - click on training and events - but I would love to see if I could have a look at their training notes. Do you know anything about these courses?
In terms of a basic set of introduction notes I found the training notes (pdf file) provided by the International Union against Tuberculosis and Lung disease very helpful. The link is http://www.tbrieder.org then go to Epidata
best wishes
Christine
>>> <epidata-list(a)lists.umanitoba.ca> 6/06/2008 7:41 p.m. >>>
Christine
These notes are really useful, thank you! Like you I have
'traditionally' used EpiData for questionnaire design and entry, and
then switched to Epi Info for Windows for the more user-friendly (to me
at least) data analysis. Hopefully your experiences will give a good
idea to others about the readiness of EpiData Analysis for use in this
type of situation.
Thanks
Alastair
---------------------------------------
Alastair Tomlinson
Chartered EHP, Lecturer in Environmental Health
029 2020 1528
AGTomlinson(a)uwic.ac.uk
-----Original Message-----
From: epidata-list(a)lists.umanitoba.ca
[mailto:epidata-list@lists.umanitoba.ca]
Sent: 05 June 2008 06:05
To: epidata-list(a)lists.umanitoba.ca
Subject: [EpiData-list] Outbreak analysis diary - Defining cases as a
newvariable
Today we started doing the analysis of exposures for our outbreak. First
we need to create a new variable, as not everyone who is sick meets the
case definition for the outbreak.
Case definition
Our case definition is someone who has diarrhoea and/or vomiting 24-72
hours after the function.
I used the programme editor to define a new variable called Case I made
case a Boolean field so the relative risks would calculate correctly
(with a Boolean field the Y appears first in a two by two table and
then the N and this is what you want to calculate relative risks
correctly).
Diarrhoea and Vomit - the fields I needed to create the Case field were
also Booklean fields. For a long time I had a problem as I was trying
many combinations of If Diarrhoea = Yes or Y or "Y" in my code and it
was not working. Then my workmate suggested I try TRUE. I think this is
confusing as when you print a Frequency of a boolean Field it prints as
Y. Anyway here was the code that worked.
Define case <Y>
If Diarrhoea = TRUE or Vomit = TRUE then case = TRUE
This deals with the first part of the case definition - that they must
have diarrhoea or vomiting. The next part is that they are NOT a case if
the symptoms started on the same day.
The code I ended up using for this was IF onsetdate <=
date("24/05/2008") then case = FALSE. I had to put the date function as
well as the date itself or the code would not run. I don't know why that
is but any other combination I tried like "24/05/2008" or 24/05/2008 or
("24/05/2008") did not work.
Onsetdate
In the last post I asked if anyone had some code to create a single
onset date from two pieces of information - the vomitdate and the
diarrhoea date. My workmate helped me figure out something that worked
and this is it.
If diadate < vomdate then onsetdate = diadate If vomdate < diadate then
onsetdate = vomdate If vomdate =diadate then onsetdate = diadate If
vomdate =(.) then onsetdate = diadate If diadate =(.) then onsetdate =
vomdate
Now we have a variables of case and onset date and I created an Epicurv
graph using them. It was great.
One more frustration. While we were working on the code we often used
browse to check our results. We wrote the browse command into the
programme editor but the results of the Browse do not appear in the
output so I had to do it over again each time in the output screen. I
tried list instead of Browse but this didn't work either. Any
suggestions for how you can build the output from a browse or line list
command into a programme will be welcome.
Next posting we will get on to analysing the exposures
thanks
Christine
--
The information contained in this email and any attachments is
confidential and may be legally privileged. If you have received this
message in error, please notify the sender immediately and remove all
copies of the message, including any attachments. Any views or opinions
expressed in this email (unless otherwise stated) may not represent
those of Hutt Valley DHB.
Thank you.
** Disclaimer added by HVDHB **
Christine Roseveare
Analyst
Regional Public Health
570 9194
027 495 9671
--
The information contained in this email and
any attachments is confidential and may be
legally privileged. If you have received this
message in error, please notify the sender
immediately and remove all copies of the message,
including any attachments. Any views or
opinions expressed in this email (unless
otherwise stated) may not represent those of
Hutt Valley DHB.
Thank you.
** Disclaimer added by HVDHB **
thanks very much Jens, Hans and Jamie for the suggestions and Alistair for the encouragement.
Hans thanks I tried your suggestion for the browse and it worked well. The other suggestions will take a bit longer to work through. I will report back when I do but this post I want to report on the analysis and also the success of creating and combining two data entry files.
Attack rate table of exposures
As has been said several times on this list but is worth saying again, the 'outbreak analysis' function in Epidata that creates a single attack rate table showing attack rates, relative risks, CIS and pvalues of all exposures of interest against the outcome of 'case' is a wonderful feature. The command is TAB CASE .....all exposures of interest/OA
The steps I took were:
1. Click on Browse Data from the menu bar
2. Tick my outcome of interest (Case) and all my exposures of interest (foods etc)
3. Click on Paste (this copies all the selected variables into the section at the bottom of the output screen)
4. I then copied this line into the programme editor, took out the browse at the start and added/OA at the end
as below:
TAB CASE ANYFOOD COURTL1 COURTL2 JUNGLEPLAY JTOILET BTOILET KIOSK M1NUGGETS M2CHEERIOS M3CHIPS M4SAUCE M5PIZZA M6JUICE M7JELLYICE M8YOGURT M9CHOCCRAC M10CAKE M11LOLLIES M12TEA M13COFFEE M14SAV M15SAND M16HOTDOG M18FISHBIT M19FISHFIL M20FRUITSA M21DANISH M22BURGER/OA
Note: Adding EX after OA gives the pvalue
I then selected run programme - this creates the attack rate table in the output screen, and also in the default output file.
I really like the outbreak analysis feature but on my wish list would be
1. for 'outbreak analysis' to be an option in one of the menus somewhere. I only knew about this feature through someone mentioning it on the list and I had to search through the docuentation to find it. Maybe this was what the 'attack rate plus RR' option was but I could not seem to select this - it stayed greyed out.
2. If a select' has been used for this to show above the attack rate table. I ran the outbreak analysis above again but this time selecting only people who had attended the centre on a certain date. The command I used was Select Day25 = TRUE
I know the select has worked because N has gone down from 251 to 66, but there is no indicaiton on the output file or the information under the attack rate table that a 'select' is in place.
Thank you all again for your feedback on these postings. I will do one maybe two more - covering the process of sending the data output to a report and a final summary of the main steps and final programme I used.
Christine
Having more than one data entry file
We ended up with 250 questionnaires so decided we would try using several data entry operators to enter the data
Christine Roseveare
Analyst
Regional Public Health
570 9194
027 495 9671
>>> <epidata-list(a)lists.umanitoba.ca> 6/06/2008 8:56 a.m. >>>
Dear Christine:
Just a quick comment on BROWSE.
Did you use the command:
set display databrowser=on
before issuing the BROWSE field1 field2 command? The default is that
the browser is off. Note that this works fine with the public release
version, but if you experiment withe (marvelous) test version build
134, there seems to be some hickup that occasionally blocks the program,
but I believe to have noted that it works if the command is in the
beginning of the program before reading the file (not yet certain).
In any case, I appreciate your telling us your experiences, they are
useful for many. Apologies for not taking the time to answer to more of
your queries, but I am currently a bit taken with traveling between
continents.
Regards,
Hans
epidata-list(a)lists.umanitoba.ca wrote:
> Today we started doing the analysis of exposures for our outbreak. First we need to create a new variable, as not everyone who is sick meets the case definition for the outbreak.
>
> Case definition
> Our case definition is someone who has diarrhoea and/or vomiting 24-72 hours after the function.
> I used the programme editor to define a new variable called Case
> I made case a Boolean field so the relative risks would calculate correctly (with a Boolean field the Y appears first in a two by two table and then the N and this is what you want to calculate relative risks correctly).
>
> Diarrhoea and Vomit - the fields I needed to create the Case field were also Booklean fields. For a long time I had a problem as I was trying many combinations of If Diarrhoea =es or Y or "Y" in my code and it was not working. Then my workmate suggested I try TRUE. I think this is confusing as when you print a Frequency of a boolean Field it prints as Y. Anyway here was the code that worked.
>
> Define case <Y>
> If Diarrhoea =RUE or Vomit = TRUE then case = TRUE
>
> This deals with the first part of the case definition - that they must have diarrhoea or vomiting. The next part is that they are NOT a case if the symptoms started on the same day.
>
> The code I ended up using for this was IF onsetdate <=ate("24/05/2008") then case = FALSE. I had to put the date function as well as the date itself or the code would not run. I don't know why that is but any other combination I tried like "24/05/2008" or 24/05/2008 or ("24/05/2008") did not work.
>
> Onsetdate
> In the last post I asked if anyone had some code to create a single onset date from two pieces of information - the vomitdate and the diarrhoea date. My workmate helped me figure out something that worked and this is it.
>
> If diadate < vomdate then onsetdate =iadate
> If vomdate < diadate then onsetdate =omdate
> If vomdate =adate then onsetdate = diadate
> If vomdate =) then onsetdate = diadate
> If diadate =) then onsetdate = vomdate
>
> Now we have a variables of case and onset date and I created an Epicurv graph using them. It was great.
> One more frustration. While we were working on the code we often used browse to check our results. We wrote the browse command into the programme editor but the results of the Browse do not appear in the output so I had to do it over again each time in the output screen. I tried list instead of Browse but this didn't work either. Any suggestions for how you can build the output from a browse or line list command into a programme will be welcome.
>
> Next posting we will get on to analysing the exposures
>
> thanks
>
> Christine
>
>
>
--
Hans L Rieder, MD, MPH
Jetzikofenstr. 12
3038 Kirchlindach
Switzerland
Tel: +41 31 829 4577
Mob: +41 79 321 9122
Web: http://www.tbrieder.org
--
The information contained in this email and
any attachments is confidential and may be
legally privileged. If you have received this
message in error, please notify the sender
immediately and remove all copies of the message,
including any attachments. Any views or
opinions expressed in this email (unless
otherwise stated) may not represent those of
Hutt Valley DHB.
Thank you.
** Disclaimer added by HVDHB **
Just a quick question re an issue I have with Epidata analysis and the C drive default directories it uses for some functions.
This is the message I get when I load Epidata Analyis
* EpiData Analysis default settings file
* Edit the next lines to change size or font
. set echo=off
Access is denied
Operation aborted
Although I can still use Epidata Analysis I do not get the option to change the settings, I don't see the results of the read command displayed or information about how many records are in the file. I also have to change the default I send the output to as I can not access the default directory. I asked our IT help desk and they say the reason this happens is that I am now allowed access to one of the directories Epidata looks for - an administrator folder in the C drive. I wonder if this might be a problem for others who are in organisations/working on networks where users are not allowed access to administrator folders. Do you have a suggested workaround?
thanks
Christine
Christine Roseveare
Analyst
Regional Public Health
570 9194
027 495 9671
>>> <epidata-list-request(a)lists.umanitoba.ca> 7/06/2008 5:04 a.m. >>>
Send EpiData-list mailing list submissions to
epidata-list(a)lists.umanitoba.ca
To subscribe or unsubscribe via the World Wide Web, visit
http://lists.umanitoba.ca/mailman/listinfo/epidata-list
or, via email, send a message with subject or body 'help' to
epidata-list-request(a)lists.umanitoba.ca
You can reach the person managing the list at
epidata-list-owner(a)lists.umanitoba.ca
When replying, please edit your Subject line so it is more specific
than "Re: Contents of EpiData-list digest..."
--
The information contained in this email and
any attachments is confidential and may be
legally privileged. If you have received this
message in error, please notify the sender
immediately and remove all copies of the message,
including any attachments. Any views or
opinions expressed in this email (unless
otherwise stated) may not represent those of
Hutt Valley DHB.
Thank you.
** Disclaimer added by HVDHB **
Today we started doing the analysis of exposures for our outbreak. First we need to create a new variable, as not everyone who is sick meets the case definition for the outbreak.
Case definition
Our case definition is someone who has diarrhoea and/or vomiting 24-72 hours after the function.
I used the programme editor to define a new variable called Case
I made case a Boolean field so the relative risks would calculate correctly (with a Boolean field the Y appears first in a two by two table and then the N and this is what you want to calculate relative risks correctly).
Diarrhoea and Vomit - the fields I needed to create the Case field were also Booklean fields. For a long time I had a problem as I was trying many combinations of If Diarrhoea = Yes or Y or "Y" in my code and it was not working. Then my workmate suggested I try TRUE. I think this is confusing as when you print a Frequency of a boolean Field it prints as Y. Anyway here was the code that worked.
Define case <Y>
If Diarrhoea = TRUE or Vomit = TRUE then case = TRUE
This deals with the first part of the case definition - that they must have diarrhoea or vomiting. The next part is that they are NOT a case if the symptoms started on the same day.
The code I ended up using for this was IF onsetdate <= date("24/05/2008") then case = FALSE. I had to put the date function as well as the date itself or the code would not run. I don't know why that is but any other combination I tried like "24/05/2008" or 24/05/2008 or ("24/05/2008") did not work.
Onsetdate
In the last post I asked if anyone had some code to create a single onset date from two pieces of information - the vomitdate and the diarrhoea date. My workmate helped me figure out something that worked and this is it.
If diadate < vomdate then onsetdate = diadate
If vomdate < diadate then onsetdate = vomdate
If vomdate =diadate then onsetdate = diadate
If vomdate =(.) then onsetdate = diadate
If diadate =(.) then onsetdate = vomdate
Now we have a variables of case and onset date and I created an Epicurv graph using them. It was great.
One more frustration. While we were working on the code we often used browse to check our results. We wrote the browse command into the programme editor but the results of the Browse do not appear in the output so I had to do it over again each time in the output screen. I tried list instead of Browse but this didn't work either. Any suggestions for how you can build the output from a browse or line list command into a programme will be welcome.
Next posting we will get on to analysing the exposures
thanks
Christine
--
The information contained in this email and
any attachments is confidential and may be
legally privileged. If you have received this
message in error, please notify the sender
immediately and remove all copies of the message,
including any attachments. Any views or
opinions expressed in this email (unless
otherwise stated) may not represent those of
Hutt Valley DHB.
Thank you.
** Disclaimer added by HVDHB **
I think this opportunity for open sharing of ideas and experiences is
very good and unique
In general I discourage the use of boolean variables. In particular
since these in many softwares can have only the values true (Y) or false
(N), and not the value "no value".
With the introduction of value labels it is far more efficient to use
integer variables, e.g. for the current outbreak:
qes file food items intaken :
v1 food item 1 (e.g. soup) #
v2 food item 2 (e.g. vanilla icecream) #
etc
Preparation of chk file is then easy.
1. add checks (#3 in entry)
2. define a value label (+) for v1:
0 no
1 yes
9 missing
3. further define "9" as missing for v1:
F9 (edit) and add
missingvalue all 9
3. after defining that go to field 1 and press ctrl+c
4. go to v2 (and all other food items) and press ctrl+v
now all fields have 0 and 1 defined and 9 as missing value.
5. enter your data
6 read data into analysis
define cases:
strategy 1:
define case #
case = 0
if (vomiting = 1) then case = 1
* remove those vomiting before 24 hours or after 72 hours
if (vomiting=1) and (hourvomit < 24) then case = 0
if (vomiting=1) and (hourvomit > 72) then case = 0
* alternatively if we have a fixed date of exposure on 21st of may)
if (vomiting=1) and (datevomit < dmy(22,5,2008) then case = 0
if (vomiting=1) and (datevomit > dmy(24,5,2008) then case = 0
* all with diarrhoea are cases:
if (diarrhoea = 1) then case = 1
* date of symptoms:
define dateonset <dd/mm/yyyy>
If diadate < vomdate then onsetdate = diadate
If vomdate < diadate then onsetdate = vomdate
If vomdate =diadate then onsetdate = diadate
If vomdate =(.) then onsetdate = diadate
If diadate =(.) then onsetdate = vomdate
* now we are ready for the first simple analysis:
tab case v1 v2 v3 .... etc - all exposure variables..... /oa /t
epicurve onsetdate case
epicurve onsetdate case /by=sex
The problems reported the latest days, such as:
using boolean variables
changing from string to numerical etc. a
Can be handled by combining entry and analysis - as was shown on the
list by others:
a. rewrite the qes file and some conversions are done by EpiData Entry
when possible
b. take the file into analysis - generate the new numerical variables, e.g.
gen i v1 = (upper(v1string) = "Y")
c. save the data (savedata newfile)
d. with entry create a qes file from the rec file (in Entry - menu tools)
e. change the format and labels in qes file and save the qes file
f. enter more data - entry will see that the qes file is new and adapt
format of rec file.
But the best strategy is to have a standard qes file and rec file from
the beginning and then adapt to the current outbreak.
Two examples of this is shown in the "field guide under way" in
http://www.epidata.org/wiki/index.php/Field_Guide
Exciting to get more news on the ongoing analysis "down under" (seen
from my perspective).
regards
Jens Lauritsen
EpiData Association