environment

ddply run in a function looks in the environment outside the function ?

Hello. I'm trying to write a function to do some often repeated analysis, and one part of this is to count the number of groups and number of members within each group, so ddply to the rescue !, however, my code has a problem.... Here is some example data > dput(BGBottles) structure(list(Machine = structure(c(1L, 1L, 1L, 2L, 2L, 2L, ...

make: Why don't environment variables override variables set in makefiles by default?

Hi all, I am compiling packages and I see that oftentimes Makefile authors write set CFLAGS in the makefile, with such and such options. I, on the other hand, would like to try out some compiler optimizations and would like to propagate the compiler switches to make with as little trouble as possible. Not always is this doable though. F...

What class of objects are in the environment ? (R)

I wish to know what type of objects I've got in my environment. I can show who is there like this: ls() But running something like sapply(ls(), class) Would (obviously) not tell us what type (class) of objects we are having (function, numeric, factor and so on...) using ls.str() Will tell me what class my objects are, but I w...

Is there a central DB SERVER in this kind of situation?

I have multiple servers containing the same table schema, but each responsible for a portion of the overall data... No one machine needs to contain all the data. Each machine only contains data relating to its department. Is there a central database server which will contain all the data, or just a central db server which can be used t...

configuration.rb problems; failed rake.

Thank you in Advance! I'm using Capistrano to cap deploy:migrations. Two commands within the environment.rb file are causing some problems: config.gem "coderay" config.gem "RedCloth" An SSH into the Dreamhost server: gem: /usr/bin/gem1.8 /usr/bin/gem /usr/share/man/man1/gem.1.gz [kinshasa]$ which gem /usr/bin/gem [kinshasa]$ gem lis...

How do I generate test data for heterogeneous environments?

I am facing a new task in my job and I need to find out how to generate and administer test data. Googling led to a lot of information about specific test data generation like filling a database with random data or camouflaged production data, generating files, generating test data with multi-objective genetic algorithms to minimize test...

Environment.CurrentDirectory renders Wrong Path

I need to get to a certain file in my ASP.NET MVC project. Have two folders in my same Project, let's call them Main and Reference. From my Main, I am calling a class from my Reference.csproj file. From there, I need to get to my TargetFile, which also lives in the Reference folder. When I use AppDomain.CurrentDomain.BaseDirectory i ge...

Environment inside a longtable with LaTeX

Hello, I would like to create a new environment to print a header and a footer between sections of a table. I did this: \documentclass{article} \usepackage{longtable} \newenvironment{env}{Heading&&& \\}{\hline \\} \begin{document} \begin{longtable}{p{7cm}lrr} \begin{env} Content&b&c&d \end{env} \end{longtable} \en...

How to retreive Active Directory environment and session information with VB.Net

I'd like to be able to get and set the different information for a user in Active Directory on Windows Server 2003 under Environment and Session tabs through a VB.Net application. I am familiar with System.DirectoryService but I can not find the correct attributes for these particular tabs. For example, I'd like to check "Connect Printer...

Creating a walk-through using Virtools

I,m doing a virtual walk-through in a museum environment. i have constructed the 3D virtual environment in 3D's Max and i need to create the walking part in Virtools. I have found some tutorials in youtube that shows how to do a simple character movement. but it shows only using keyboard navigations to move around. I want to know how to...

How to get data to a running ruby process?

I have a datastore with a cache and a db, simple. The tricksy part is that I want a way to control if the the datastore hits the db in a real-time way. That is to say while the process is running I want to be able to toggle if it's connected to the db or not. I looked into env variables, but it doesn't seem like those get updated as t...

How to change default path for images to look for

By default, rails is looking for images to "public/images" folder. But it is not suiteable for me, since i have all the multimedia stuff in "public/data/:model/:id" folders. How do i force rails to look into this folder. I don't need obligatory such a pattern, that i mentioned above. The only thing, i need, is just to change "public/i...

How to manage poperty files for different application instances?

Hi All! I think in our project we have the common problem for really big projects... We have 4 regions in which our system is installed - Europe, USA, ASIA and Japan.. Each region has 3 types of environment - dev, test and prod. For each environment we have property file where we are specifying configurations for instances. In whole we ...

What type of music produces the best productivity while programming?

Possible Duplicate: Audio while programming I know it's not an actual code how-to question...I also know it varies from coder to coder, but... It would be useful for me to see what other people have to say about it. So what have you all found to be the best for you? Hard Rock? Classical? Techno? Does it just depend on your mo...

How can I determine if my process is being run interactively?

Is there a standard(ish) POSIX way of determining if my process (I’m writing this as a Ruby script right now; but I’m curious for multiple environments, including Node.js and ISO C command-line applications) is being run in an interactive terminal, as opposed to, say, cron, or execution from another tool, or… so on and so forth. Specifi...

Calling PowerShell from batch, and retrieving the new value of a temporary environment variable set in the script?

Hey guys! I hope the title is concise, but just in case: I am calling a PowerShell script from a batch file. I want the PowerShell script to set the value of an environment variable, and for that new value to be available in the batch file when the PowerShell script finishes. I know that it is possible to set an environment variable u...

sed, environment variable and date problem

I want to add a timestamp to server events and store the result in a log. My first idea was : ( ./runServer.sh ) | sed "s/.*/`date +%s` & /" | xargs -0 >Server.log 2>&1 & But it seems sed never reevaluates the date, so all events get the same timestamp. Now I'm trying to get around that using environment variable but I can't find ...

In R, how do you evaluate ... in the calling function?

If I want to know what is stored in a ... argument within an R function, I can simply convert it to be a list, like so foo <- function(...) { dots <- list(...) print(dots) } foo(x = 1, 2, "three") #$x #[1] 1 # #[[2]] #[1] 2 # #[[3]] #[1] "three" What I can't figure out is how to evaluate ... in the calling function. In this next...

Get an environment variable into a WIX property

Hi, Is there a way to get an environment variable in WIX into a property? I'm trying to get the USERPROFILE with: Property Id="UserFolder" Value="$(env.USERPROFILE)\EdwardsApp\MyFolder" But this only picks up the USERPROFILE of the build machine, where the installer is built. I want it to use the USERPROFILE of the machine where th...

Custom Environment Variables in PHP

Is there a way to set a custom variable such as environment_name in my apache vhost file that can be read via $_ENV or ini_get("environment_name")? ...