Search Results

Search found 1870 results on 75 pages for 'matt mcclellan'.

Page 49/75 | < Previous Page | 45 46 47 48 49 50 51 52 53 54 55 56  | Next Page >

  • Recommended reading for bioinformatics

    - by Matt
    I'm keen on learning about bioinformatics. I am ideally looking for a short course introduction, with some practical tasks I can get my teeth into immediately to see if there is any interest in it for me. I already have a good understanding of molecular biology, so I should be able to skip most of the foundational work. Any suggestions?

    Read the article

  • Screen information while Windows system is locked (.NET)

    - by Matt
    We have a nightly process that updates applications on a user's pc, and that requires bringing the application down and back up again (not looking to get into changing that process). The problem is that we are building a Windows AppBar on launch which requires a valid screen, and when the system is locked there isn't one in the Screen class. So none of the visual effects are enabled and it shows up real ugly. The only way we currently have around this is to detect a locked screen and just spin and wait until the user unlocks the desktop, then continue launching. Leaving it down isn't an option, as this is a key part of our user's workflow, and they expect it to be up and running if they left it that way the night before. Any ideas?? I can't seem to find the display information anywhere, but it has to be stored off someplace, since the user is still logged in. The contents of the Screen.AllScreens array: ** When Locked: Device Name : DISPLAY Primary : True Bits Per Pixel : 0 Bounds : {X=-1280,Y=0,Width=2560,Height=1024} Working Area : {X=0,Y=0,Width=1280,Height=1024} ** When Unlocked: Device Name : \\.\DISPLAY1 Primary : True Bits Per Pixel : 32 Bounds : {X=0,Y=0,Width=1280,Height=1024} Working Area : {X=0,Y=0,Width=1280,Height=994} Device Name : \\.\DISPLAY2 Primary : False Bits Per Pixel : 32 Bounds : {X=-1280,Y=0,Width=1280,Height=1024} Working Area : {X=-1280,Y=0,Width=1280,Height=964}

    Read the article

  • Objective-C method not being called

    - by Matt S.
    It's either because of the fact I'm tired or because I'm doing it wrong, but for some reason I can't get it to call a method. Here's what I'm trying to call: -(void)newHighScore:(int)d Which right now just does an NSLog saying "yea I'm working!" I'm calling it like this: [highscore newHighScore:score]; highscore is what I called the HighScore class in the .h, and score is an int with the score.

    Read the article

  • R selecting duplicate rows

    - by Matt
    Okay, I'm fairly new to R and I've tried to search the documentation for what I need to do but here is the problem. I have a data.frame called heeds.data in the following form (some columns omitted for simplicity) eval.num, eval.count, ... fitness, fitness.mean, green.h.0, green.v.0, offset.0, green.h.1, green.v.1,...green.h.7, green.v.7, offset.7... And I have selected a row meeting the following criteria: best.fitness <- min(heeds.data$fitness.mean[heeds.data$eval.count = 10]) best.row <- heeds.data[heeds.data$fitness.mean == best.fitness] Now, what I want are all of the other rows with that have columns green.h.0 to offset.7 (a contiguous section of columns) equal to the best.row Basically I'm looking for rows that have some of the conditions the same as the "best" row. I thought I could just do this, heeds.best <- heeds.data$fitness[ heeds.data$green.h.0 == best.row$green.h.0 & ... ] But with 24 columns it seems like a stupid method. Looking for something a bit simpler with less manual typing. Thanks!

    Read the article

  • How do you deal with duplicate street suffixes?

    - by Matt
    I have a system where users need to enter addresses. I am trying to limit duplicates of course and something I started noticing was becoming a big problem was some users putting in "Road" and others "Rd", therefore duplicates were creeping in. I looked up the list of USPS street suffix abbreviations but I still have a question which I can't find an answer to. Can I replace all words in a street address with the USPS standard abbreviation? An example would be "123 Forest Hill Road". If I were to replace it with the abbreviations it would then be "123 Frst Hl Rd" or does the "street suffix" that USPS is referring to mean they only want you to make go as far as "123 Forest Hill Rd"?

    Read the article

  • Which are the most important media queries to use in creating mobile responsive design?

    - by Matt
    There are a lot different media queries for mobile screen sizes. It can be overwhelming to accomodate all of them when designing a responsive mobile site. Which are the most important ones to use when designing for mobile? I found this article that does a pretty good job of outlining the available media queries: http://css-tricks.com/snippets/css/media-queries-for-standard-devices/. /* Smartphones (portrait and landscape) ----------- */ @media only screen and (min-device-width : 320px) and (max-device-width : 480px) { /* Styles */ } /* Smartphones (landscape) ----------- */ @media only screen and (min-width : 321px) { /* Styles */ } /* Smartphones (portrait) ----------- */ @media only screen and (max-width : 320px) { /* Styles */ } /* iPads (portrait and landscape) ----------- */ @media only screen and (min-device-width : 768px) and (max-device-width : 1024px) { /* Styles */ } /* iPads (landscape) ----------- */ @media only screen and (min-device-width : 768px) and (max-device-width : 1024px) and (orientation : landscape) { /* Styles */ } /* iPads (portrait) ----------- */ @media only screen and (min-device-width : 768px) and (max-device-width : 1024px) and (orientation : portrait) { /* Styles */ } /* Desktops and laptops ----------- */ @media only screen and (min-width : 1224px) { /* Styles */ } /* Large screens ----------- */ @media only screen and (min-width : 1824px) { /* Styles */ } /* iPhone 4 ----------- */ @media only screen and (-webkit-min-device-pixel-ratio : 1.5), only screen and (min-device-pixel-ratio : 1.5) { /* Styles */ }

    Read the article

  • Mocking HtmlHelper throws NullReferenceException

    - by Matt Austin
    I know that there are a few questions on StackOverflow on this topic but I haven't been able to get any of the suggestions to work for me. I've been banging my head against this for two days now so its time to ask for help... The following code snippit is a simplified unit test to demonstrate what I'm trying to do, which is basically call RadioButtonFor in the Microsoft.Web.Mvc assembly in a unit test. var model = new SendMessageModel { SendMessageType = SendMessageType.Member }; var vd = new ViewDataDictionary(model); vd.TemplateInfo = new TemplateInfo { HtmlFieldPrefix = string.Empty }; var controllerContext = new ControllerContext(new Mock<HttpContextBase>().Object, new RouteData(), new Mock<ControllerBase>().Object); var viewContext = new Mock<ViewContext>(new object[] { controllerContext, new Mock<IView>().Object, vd, new TempDataDictionary(), new Mock<TextWriter>().Object }); viewContext.Setup(v => v.View).Returns(new Mock<IView>().Object); viewContext.Setup(v => v.ViewData).Returns(vd).Callback(() => {throw new Exception("ViewData extracted");}); viewContext.Setup(v => v.TempData).Returns(new TempDataDictionary()); viewContext.Setup(v => v.Writer).Returns(new Mock<TextWriter>().Object); viewContext.Setup(v => v.RouteData).Returns(new RouteData()); viewContext.Setup(v => v.HttpContext).Returns(new Mock<HttpContextBase>().Object); viewContext.Setup(v => v.Controller).Returns(new Mock<ControllerBase>().Object); viewContext.Setup(v => v.FormContext).Returns(new FormContext()); var mockContainer = new Mock<IViewDataContainer>(); mockContainer.Setup(x => x.ViewData).Returns(vd); var helper = new HtmlHelper<ISendMessageModel>(viewContext.Object, mockContainer.Object, new RouteCollection()); helper.RadioButtonFor(m => m.SendMessageType, "Member", cssClass: "selector"); If I remove the cssClass parameter then the code works ok but fails consistently when adding additional parameters. I've tried every combination of mocking, instantiating concrete types and using fakes that I can think off but I always get a NullReferenceException when I call RadioButtonFor. Any help hugely appreciated!!

    Read the article

  • XML Serializing a class with a Dictionary<string, List<string>> object

    - by Matt
    Is it possible to implement IXmlSerializable and in my XML file capture an object of type Dictionary ? I have the following public class coolio : IXmlSerializable { private int a; private bool b; private string c; private Dictionary<string, List<string>> coco; public coolio(int _a, bool _b, string _c, Dictionary<string, List<string>> _coco) { a=_a; b=_b; c=_c; coco=_coco; } public System.Xml.Schema.XmlSchema GetSchema() { return null; } public void WriteXml(XmlWriter writer) { const string myType = "coolio"; writer.WriteStartElement(myType); writer.WriteAttributeString("a", a.ToString()); writer.WriteAttributeString("b", b.ToString()); writer.WriteAttributeString("c", c); // How do I add a subelement for Dictionary<string, List<string>> coco? writer.WriteEndElement(); } public void ReadXml(XmlReader reader) { if (reader.MoveToContent() != XmlNodeType.Element || reader.LocalName != "coolio") return; a= int.Parse(reader["a"]); b = bool.Parse(reader["b"]); c= reader["c"]; // How do I read subelement into Dictionary<string, List<string>> coco? } } But I am stumped as to how I could add the Dictionary (XML seriliazed to my XML file)

    Read the article

  • Unit Testing Model Classes that derive from NSManagedObject

    - by Matt Baker
    So...I'm trying to get unit tests set up in my iPhone App but I'm having some issues. I'm trying to test my model classes but they inherit directly from NSManagedObject. I'm sure this is a problem but I don't know how to get around it. Everything is building and running as expected but I get this error when calling any method on the class I'm testing: Unknown.m:0:0 unrecognized selector sent to instance 0xc2b120 If I follow this structure (http://chanson.livejournal.com/115621.html) to create my object in my tests I end up with another error entirely but it still doesn't help me. Basically my question is this: how can I test a class that inherits from NSManagedObject?

    Read the article

  • Best way to store 3 pieces of data as a single entry

    - by Matt
    For a game server, I want to record details when a player makes a kill, store this, and then at intervals update to a sql database. The part i'm interested in right now is the best method of storing the kill information. What i'd like to pass to the sql server on update would be {PlayerName, Kills, Deaths}, where the kills and deaths are a sum for the period between updates. So i'm assuming i'd build a list along the lines of {bob, 1, 0} {frank, 0, 1} {tom, 1, 0} {frank, 0, 1} then on update, consolidate the list to {frank, 14, 3}etc Can someone offer some advice please?

    Read the article

  • Any C/C++ to non-native bytecode compiler/interpreters?

    - by Matt
    As the title indicates, are there any C/C++ bytecode compilers/interpreters? I'm writing an application in an interpreted language that depends on certain libraries that are fully cross-compilable (there are no special flags to indicate code changes during compilation for a certain platform) but are written in C and C++. Rather than shipping n-platform-specific-libs with each platform, it would be nice to ship one set of libs which are interpreted by one platform specific interpreter. Possible and/or available?

    Read the article

  • How do I ensure a Flex dataProvider processes the data synchronously?

    - by Matt Calthrop
    I am using an component, and currently have a dataProvider working that is an ArrayCollection (have a separate question about how to make this an XML file... but I digress). Variable declaration looks like this: [Bindable] private var _dpImageList : ArrayCollection = new ArrayCollection([ {"location" : "path/to/image1.jpg"}, {"location" : "path/to/image2.jpg"}, {"location" : "path/to/image3.jpg"} ]); I then refer to like this: <s:List id="lstImages" width="100%" dataProvider="{_dpImageList}" itemRenderer="path.to.render.ImageRenderer" skinClass="path.to.skins.ListSkin" > <s:layout> <s:HorizontalLayout gap="2" /> </s:layout> </s:List> Currently, it would appear that each item is processed asynchronously. However, I want them to be processed synchronously. Reason: I am displaying a list of images, and I want the leftmost one rendered first, followed by the one to its right, and so on. Edit: I just found this answer. Do you think that could be the same issue?

    Read the article

  • Python sorting problem

    - by matt
    I'm sure this is simple but I can't figure it out. I have a list of strings like this(after using sorted on it): Season 2, Episode 1: A Flight to Remember Season 2, Episode 20: Anthology of Interest I Season 2, Episode 2: Mars University Season 2, Episode 3: When Aliens Attack .... Season 3, Episode 10: The Luck of the Fryrish Season 3, Episode 11: The Cyber House Rules Season 3, Episode 12: Insane in the Mainframe Season 3, Episode 1: The Honking Season 3, Episode 2: War Is the H-Word How can I make them sort out properly? (by episode #, ascending)

    Read the article

  • Avoiding string copying in Lua

    - by Matt Sheppard
    Say I have a C program which wants to call a very simple Lua function with two strings (let's say two comma separated lists, returning true if the lists intersect at all, false if not). The obvious way to do this is to push them onto the stack with lua_pushstring, which works fine, however, from the doc it looks like lua_pushstring but makes a copy of the string for Lua to work with. That means that to cross over to the Lua function is going to require two string copies which I could avoid by rewriting the Lua function in C. Is there any way to arrange things so that the existing C strings could be reused on the Lua side for the sake of performance (or would the strcpy cost pale into insignificance anyway)? From my investigation so far (my first couple of hours looking seriously at Lua), lite userdata seems like the sort of thing I want, but in the form of a string.

    Read the article

  • Can I make Visual Studio's code completion window more like Eclipse (Java)?

    - by Matt
    Is it possible to make Visual Studio 2010's code completion window more like that of Eclipse (Java)? In particular, I'd love the code completion window to give me a variable's type, and a method's return type and expected parameters, without needing to hover the highlight over that particular variable/method. VS's code completion's little icons that indicate if something is a property, method etc are useful, but they just aren't enough.

    Read the article

  • Maximizing the number of threads to fully utilize all available resources without hindering overall

    - by Matt
    Let's say I have to generate a bunch of result files, and I want to make it as fast as possible. Each result file is generated independently of any other result file; in fact, one could say that each result file is agnostic to every other result file. The resources used to generate each result file is also unique to each. How can I dynamically decide the optimal number of threads to run simultaneously in order to minimize the overall run time? Is my only option to write my own thread manager that watches performance counters and adjust accordingly or does there exists some solid classes that already accomplish this?

    Read the article

  • How to get associated URLRequest from Event.COMPLETE fired by URLLoader

    - by matt lohkamp
    So let's say we want to load some XML - var xmlURL:String = 'content.xml'; var xmlURLRequest:URLRequest = new URLRequest(xmlURL); var xmlURLLoader:URLLoader = new URLLoader(xmlURLRequest); xmlURLLoader.addEventListener(Event.COMPLETE, function(e:Event):void{ trace('loaded',xmlURL); trace(XML(e.target.data)); }); If we need to know the source URL for that particular XML doc, we've got that variable to tell us, right? Now let's imagine that the xmlURL variable isn't around to help us - maybe we want to load 3 XML docs, named in sequence, and we want to use throwaway variables inside of a for-loop: for(var i:uint = 3; i > 0; i--){ var xmlURLLoader:URLLoader = new URLLoader(new URLRequest('content'+i+'.xml')); xmlURLLoader.addEventListener(Event.COMPLETE, function(e:Event):void{ trace(e.target.src); // I wish this worked... trace(XML(e.target.data)); }); } Suddenly it's not so easy, right? I hate that you can't just say e.target.src or whatever - is there a good way to associate URLLoaders with the URL they loaded data from? Am I missing something? It feels unintuitive to me.

    Read the article

  • Probelm with String.split() in java

    - by Matt
    What I am trying to do is read a .java file, and pick out all of the identifiers and store them in a list. My problem is with the .split() method. If you run this code the way it is, you will get ArrayOutOfBounds, but if you change the delimiter from "." to anything else, the code works. But I need to lines parsed by "." so is there another way I could accomplish this? import java.io.BufferedReader; import java.io.FileNotFoundException; import java.io.FileReader; import java.io.IOException; import java.util.*; public class MyHash { private static String[] reserved = new String[100]; private static List list = new LinkedList(); private static List list2 = new LinkedList(); public static void main (String args[]){ Hashtable hashtable = new Hashtable(997); makeReserved(); readFile(); String line; ListIterator itr = list.listIterator(); int listIndex = 0; while (listIndex < list.size()) { if (itr.hasNext()){ line = itr.next().toString(); //PROBLEM IS HERE!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! String[] words = line.split("."); //CHANGE THIS AND IT WILL WORK System.out.println(words[0]); //TESTING TO SEE IF IT WORKED } listIndex++; } } public static void readFile() { String text; String[] words; BufferedReader in = null; try { in = new BufferedReader(new FileReader("MyHash.java")); //NAME OF INPUT FILE } catch (FileNotFoundException ex) { Logger.getLogger(MyHash.class.getName()).log(Level.SEVERE, null, ex); } try { while ((text = in.readLine()) != null){ text = text.trim(); words = text.split("\\s+"); for (int i = 0; i < words.length; i++){ list.add(words[i]); } for (int j = 0; j < reserved.length; j++){ if (list.contains(reserved[j])){ list.remove(reserved[j]); } } } } catch (IOException ex) { Logger.getLogger(MyHash.class.getName()).log(Level.SEVERE, null, ex); } try { in.close(); } catch (IOException ex) { Logger.getLogger(MyHash.class.getName()).log(Level.SEVERE, null, ex); } } public static int keyIt (int x) { int key = x % 997; return key; } public static int horner (String word){ int length = word.length(); char[] letters = new char[length]; for (int i = 0; i < length; i++){ letters[i]=word.charAt(i); } char[] alphabet = new char[26]; String abc = "abcdefghijklmnopqrstuvwxyz"; for (int i = 0; i < 26; i++){ alphabet[i]=abc.charAt(i); } int[] numbers = new int[length]; int place = 0; for (int i = 0; i < length; i++){ for (int j = 0; j < 26; j++){ if (alphabet[j]==letters[i]){ numbers[place]=j+1; place++; } } } int hornered = numbers[0] * 32; for (int i = 1; i < numbers.length; i++){ hornered += numbers[i]; if (i == numbers.length -1){ return hornered; } hornered = hornered % 997; hornered *= 32; } return hornered; } public static String[] makeReserved (){ reserved[0] = "abstract"; reserved[1] = "assert"; reserved[2] = "boolean"; reserved[3] = "break"; reserved[4] = "byte"; reserved[5] = "case"; reserved[6] = "catch"; reserved[7] = "char"; reserved[8] = "class"; reserved[9] = "const"; reserved[10] = "continue"; reserved[11] = "default"; reserved[12] = "do"; reserved[13] = "double"; reserved[14] = "else"; reserved[15] = "enum"; reserved[16] = "extends"; reserved[17] = "false"; reserved[18] = "final"; reserved[19] = "finally"; reserved[20] = "float"; reserved[21] = "for"; reserved[22] = "goto"; reserved[23] = "if"; reserved[24] = "implements"; reserved[25] = "import"; reserved[26] = "instanceof"; reserved[27] = "int"; reserved[28] = "interface"; reserved[29] = "long"; reserved[30] = "native"; reserved[31] = "new"; reserved[32] = "null"; reserved[33] = "package"; reserved[34] = "private"; reserved[35] = "protected"; reserved[36] = "public"; reserved[37] = "return"; reserved[38] = "short"; reserved[39] = "static"; reserved[40] = "strictfp"; reserved[41] = "super"; reserved[42] = "switch"; reserved[43] = "synchronize"; reserved[44] = "this"; reserved[45] = "throw"; reserved[46] = "throws"; reserved[47] = "trasient"; reserved[48] = "true"; reserved[49] = "try"; reserved[50] = "void"; reserved[51] = "volatile"; reserved[52] = "while"; reserved[53] = "="; reserved[54] = "=="; reserved[55] = "!="; reserved[56] = "+"; reserved[57] = "-"; reserved[58] = "*"; reserved[59] = "/"; reserved[60] = "{"; reserved[61] = "}"; return reserved; } }

    Read the article

  • On Solaris, how do you mount a second zfs system disk for diagnostics?

    - by Matt Ball
    I've got two hard disks in my computer, and have installed Solaris 10u8 on the first and Opensolaris 2010.3 (dev onnv_134) on the second. Both systems uses ZFS and were independently created with a zpool name of 'rpool'. While running Solaris 10u8 on the first disk, how do I mount the second ZFS hard disk (at /dev/dsk/c1d1s0) on an arbitrary mount point (like /a) for diagnostics?

    Read the article

  • Find slow/ineffecient method calls in dotnet

    - by Matt Thrower
    Hi, I'm faced with a big old stack of method calls in some legacy code, one or some of which is creating a bottleneck and really slowing things down. Is there any quick way I can get a report on which method calls are taking the time, short of running in debug, stepping through and seeing where the cursor pauses?

    Read the article

  • Problems finding classes in namespace and testing extend expected parent

    - by Matt
    So I am in the process of building a site in ASP.Net MVC, and in the process I am adding certain things to my Site.Master I want to make sure that all of my model classes extend a certain base class that contains all of the pieces the Site.Master needs to be operable. I want to test to make sure this assumption isn't broken (I believe this will save me time when I forget about it and can't figure out why a new combination isn't working.) I wrote a test that I thought would help with this, but I am running into two problems. First it isn't finding the one example model class I have so far in the LINQ call all of a sudden, I am admittedly still a bit new to LINQ. Second, I had it finding the class earlier, but I couldn't get it to verify that the class inherits from the base class. Here is the example test. [Test] public void AllModelClassesExtendAbstractViewModel() { var abstractViewModelType = typeof (AbstractViewModel); Assembly baseAssembly = Assembly.GetAssembly(abstractViewModelType); var modelTypes = baseAssembly.GetTypes() .Where(assemblyType => (assemblyType.Namespace.EndsWith("Models") && assemblyType.Name != "AbstractViewModel")) .Select(assemblyType => assemblyType); foreach (var modelType in modelTypes) { Assert.That(modelType.IsSubclassOf(abstractViewModelType), Is.True , modelType.Name + " does not extend AbstractViewModel"); } }

    Read the article

< Previous Page | 45 46 47 48 49 50 51 52 53 54 55 56  | Next Page >